Home. 
.

transparent

transparent

transparent

Altova Mailing List Archives


[xsl] Help with XPath statement

From: Raymond Bissonnette <raybiss@----------->
To:
Date: 3/1/2008 10:35:00 PM
Hi,

Given the following xml, I'd like to get the 0803 (last) section's set
elements + the 0802 (before last) set elements that are not already in 0803.


<application>
   <section id="0802">
    <set key="jazz" value="4" />
    <set key="pop" value="61" />
    <set key="rock" value="43" />
  </section>
  <section id="0803">
    <set key="jazz" value="2" />
    <set key="vocal" value="2" />
  </section>
</application>

In this case: 

jazz
vocal
pop
rock

Here's what I came up with so far but it still misses an important part: ???

//section[@id='0803']/set|//section[@id='0802']/set[count(//section[@id='080
3']/set[@key=???]) = 0]

I tried things like self::@key and {@key} without success.

Any help would be welcome.

Regards,
Raymond


transparent
Print
Mail
Like It
Disclaimer
.

These Archives are provided for informational purposes only and have been generated directly from the Altova mailing list archive system and are comprised of the lists set forth on www.altova.com/list/index.html. Therefore, Altova does not warrant or guarantee the accuracy, reliability, completeness, usefulness, non-infringement of intellectual property rights, or quality of any content on the Altova Mailing List Archive(s), regardless of who originates that content. You expressly understand and agree that you bear all risks associated with using or relying on that content. Altova will not be liable or responsible in any way for any content posted including, but not limited to, any errors or omissions in content, or for any losses or damage of any kind incurred as a result of the use of or reliance on any content. This disclaimer and limitation on liability is in addition to the disclaimers and limitations contained in the Website Terms of Use and elsewhere on the site.

.
.

transparent

transparent