Subject: [xsl] Before & after From: Kim <kimba_40@xxxxxxxxx> Date: Wed, 25 Sep 2002 23:50:27 -0700 (PDT) |
Hi, I am running into a dilemma to print out/combine the result of several element's value with the same sibling info. Here is a fragment of the xml file: [...] <books> <publisher> a </publisher> <date> <author> b1 </author> <title name="c1"> <isbn> 100 </isbn> </title> <title name="c2"> <isbn> 101 </isbn> </title> </date> <publisher> a </publisher> <date> <author> b2 </author> <title name="c3"> <isbn> 102 </isbn> </title> </date> [...] The required output is: Publisher: a Author: b1 title: c1; isbn= 100 title: c2 ; isbn= 101 Publisher: a Author: b2 title: c3; isbn= 102 when ALL publisher,author, and title is matched to the order: a, (b1,b2) (c1, c2,c3). Precisely, I need to combine all the matched titles under non-duplicated matched author & publisher. What approach should I be taking? The problem I am having is that either the output would be w/ duplicated Publisher & Author: Publisher: a Author: b1 title: c1; isbn= 100 Publisher: a Author: b1 title: c2; isbn= 101 or it would print out the lines of: Publisher: a Author: b when the searched title is "e" which is not a matched title. What I want to do is print out only the title when the publisher and author's info are the same; else (if the author is different; eg. b2) then print out the publisher, author, and title. Is there a "before and after" in XSLT? It is not a procedural language as I currently understand. :>))) Many thanks in advance, Kim ===== Kim ************************* May the force be with you. ************************* __________________________________________________ Do you Yahoo!? New DSL Internet Access from SBC & Yahoo! http://sbc.yahoo.com XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
RE: [xsl] Before & after, Jarno . Elovirta | Thread | [xsl] adding attribute to copy, Sascha Aßbach |
[xsl] adding attribute to copy, Sascha Aßbach | Date | RE: [xsl] adding attribute to copy, Jarno . Elovirta |
Month |