[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Counting unique node values using XSLT?

Subject: Counting unique node values using XSLT?
From: "Brucato, Greg" <GBrucato@xxxxxxxxxxxx>
Date: Fri, 1 Jun 2001 16:13:16 -0400
xsl count unique
I am using the count() function to successfully count the number of nodes
produced in XML data created using Java.

However, I now have a situation where some of the values are duplicates. Is
there any way to count only unique values?

Example: The count should be 6 not 8 since there are two duplicates in the
second fragment.

<xsl:value-of select="count(trunk-groups/tg)"/>




 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list

Current Thread


Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
First Name
Last Name
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.