Could someone explain me how this xslt works in biztalk? if i want to change
the node path to full path, how to do it?
<xsl:variable name="unique-countries"
select="//cities/city[not(@country=preceding-sibling::city/@country)]/@country" />
<countries>
<xsl:for-each select="$unique-countries">
<country name="{.}">
<xsl:for-each select="//city[@country=current()]">
<city><xsl:value-of select="@name" /></city>
</xsl:for-each>
</country>
</xsl:for-each>
</countries>
I am working on grouping nodes using XSLT in biztalk. I used the above XSLT
( i got it from online) and I got output without child nodes, Cuntry.
It looks like It didn't enter into for loop. I think I need to give node
full path.
Could someone tell me which places i need to change? I tried, no luck so far.
Thank you in advance,
Siva
--
Thank you,
Siva
the first for-each results in a list of coutries.
You must step one level up...
<xsl:for-each select="../city[@country=current()]">
==> you get all the countries matching the current country.
Siva