|
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: XPATH: get not repeated nodes
But since you haven't said what the input file looks like, or what output you expect, or what output you got, it's impossible to do anything other than make blind guesses. Sorry, here I send part of the xml: <?xml version="1.0" encoding="ISO-8859-1"?>
<DATOS>
<VERSIONES>
<V14 cod="1CA8A5H7P5..9X" lit="VERSION1" ord="0000000">
<V16 cod="1CA8A5H7P5019X20" as="20">
<VEH codcol="3Y" codtap="Z6FL" tap="Z6FL"/>
<VEH codcol="5K" codtap="Z6FL" tap="Z6FL"/>
</V16>
</V14>
<V14 cod="1CA8ADH7P5..A0" lit="VERSION2" ord="2">
<V16 cod="1CA8ADH7P501A032" as="32">
<VEH codcol="KQ" codtap="Z2FT" tap="Z2FT"/>
<VEH codcol="5U" codtap="Z2FT" tap="Z2FT"/>
<VEH codcol="3Y" codtap="Z2FT" tap="Z2FT"/>
</V16>
<V16 cod="1CA8ADH7P501A031" as="31">
<VEH codcol="5U" codtap="Z2FT" tap="Z2FT"/>
<VEH codcol="3Y" codtap="Z2FT" tap="Z2FT"/>
</V16>
<V16 cod="1CA8ADH7P501A030" as="30">
<VEH codcol="3Y" codtap="Z2FZ" tap="Z2FZ"/>
<VEH codcol="3Y" codtap="Z2FT" tap="Z2FT"/>
</V16>
</V14>
<V14 cod="1CA8A5J6P5..A0" lit="VERSION3" ord="2">
<V16 cod="1CA8A5J6P501A031" as="31">
<VEH codcol="ZR" codtap="Z2FT" tap="Z2FT"/>
<VEH codcol="4A" codtap="Z2FT" tap="Z2FT"/>
<VEH codcol="3Y" codtap="Z2FT" tap="Z2FT"/>
</V16>
<V16 cod="1CA8A5J6P501A030" as="30">
<VEH codcol="ZR" codtap="Z2FZ" tap="Sirius Gris Arm.Bito"/>
<VEH codcol="ZR" codtap="Z2FT" tap="Z2FT"/>
</V16>
<V16 cod="1CA8A5J6P501A020" as="20">
<VEH codcol="KQ" codtap="Z2FZ" tap="Z2FZ"/>
<VEH codcol="7Z" codtap="Z2FG" tap="Z2FG"/>
<VEH codcol="5K" codtap="Z2FL" tap="Z2FL"/>
</V16>
</V14>
</VERSIONES>
<COLORES>
<COL cod="3H" lit="Azul Grand Pavois"/>
<COL cod="3Y" lit="Azul Lucia"/>
<COL cod="4A" lit="Grilyne"/>
<COL cod="5K" lit="Azul Mauritius"/>
<COL cod="5U" lit="Azul Oriental"/>
<COL cod="7Z" lit="Verde Hurlevent"/>
<COL cod="8Y" lit="Verde Lenz"/>
<COL cod="C1" lit="Amarillo Heliodoro"/>
<COL cod="KQ" lit="Rojo Lucifer"/>
<COL cod="WP" lit="Blanco Banquise"/>
<COL cod="X9" lit="Rojo Ardent"/>
<COL cod="XY" lit="Negro Onyx"/>
<COL cod="YT" lit="Gris Orageux"/>
<COL cod="ZR" lit="Gris Aluminio"/>
</COLORES>
</DATOS>
I have tried with: -- //V14/V16/VEH[not(@tap=preceding::VEH/@tap)] -- it gives the VEH wich diferent values of 'tap' but that exists in the whole document. -- //V14/V16/VEH[not(@tap=preceding::V14[cod='1CA8ADH7P5..A0']/V16/VEH/@tap)] -- it gives back all the VEH
both xpath give nothing. I have tried with a lot more but they had no sense, I'm lost... I want that when select a 'V14' in the select of versions the select of 'tap' fill automatic without repeating values, and the same with 'colores' and 'as'. This sounds like a grouping problem (based on the subject line) so you may want to check the faq and jeni's site for grouping hints. I will look for information there to seeing if I find something. Thanks!! Vero. _________________________________________________________________ Dale rienda suelta a tu tiempo libre. Encuentra mil ideas para exprimir tu ocio con MSN Entretenimiento. http://entretenimiento.msn.es/ 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
|

Cart








