[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: Re: Comma concatenation for all unique node value
Hi , I am using XSLT 1.0 and I have tried the mentioned logic <xsl:variable name="itemsOfthisProduct" select="//LINE_ITEM"/> <!--<xsl:value-of select="count($itemsOfthisProduct/PRODUCT_NUMBER[generate-id() = generate-id(key('getUniqueData',.))])"/> <xsl:for-each select="$itemsOfthisProduct/PRODUCT_NUMBER[generate-id() = generate-id(key('getUniqueData',.))]"> --> <!--<xsl:for-each select="//SAP_PRODUCT_NUMBER[not(.=preceding::SAP_PRODUCT_NUMBER)][following-sibling:CUST_MSG= 'Y']"> --> <xsl:for-each select="$itemsOfthisProduct/PRODUCT_NUMBER[generate-id() = generate-id(key('getUniqueData',.))][following-sibling::CUST_WARN[1]= 'Y']"> <!--<xsl:if test="position() > 1"><xsl:text>, </xsl:text></xsl:if>--> <xsl:value-of select="./PRODUCT_NUMBER"/> <xsl:if test="position() < last()-1"><xsl:text>, </xsl:text></xsl:if> <xsl:if test="position()=last()-1"><xsl:text> and </xsl:text></xsl:if> <xsl:if test="position()=last()"><xsl:text>.</xsl:text></xsl:if> </xsl:for-each> It works on most of the cases It is not showing the If the same product number first one with "Y" and second one with "N" and it is ignoring it. How I could make it display it? Any suggestions !!! Thanks, Senthil On 3/30/07, Mukul Gandhi <gandhi.mukul@xxxxxxxxx> wrote: With XSLT 2.0, you can do as following:
|
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
|