[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] The comparison after inner for-each iterartion.
Hi, I am using two for loops for node comaparison. My xml is like this: <Xml> <Info> <Personnel> <Name first="Peter" last="Golf" /> <Name first="Alex" last="John" /> </Personnel> <Prof> <Name first="Mery" last="Joe" /> <Name first="Andrew" last="Bush"> </Prof> </Info> </Xml> In my output I want to do like: If <Name> child from <Personnel> node has same value of ' first' attribute as in Prof/Name then Personnel/Name will not be written to output. Now I do this using two for-each. Here I first get first node form Personnel/Name and compare it with Prof/Name nodes in one for-each loop. There will be one more for-each to keep track of Personnel/Name nodes. When I am finished with the all Prof/Name iteration then only I want some value to return to indicate that match is found or not and not after each node comparison. I get the result after each node comparison which I don't want. Please suggest if any imroved way to do this or some solution for my approach. Thanx, Yogesh. XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|