[xsl] Handling Duplicate Lines in XSL

Subject: [xsl] Handling Duplicate Lines in XSL
From: "Jens Serna" <jserna@xxxxxxxxxxxxxxxxxxx>
Date: Wed, 29 Oct 2003 16:00:13 -0600
I have an XML file with multiple rows which are the same:

Cust1 443 West
Cust1 443 West
Cust1 443 West

Is there any way to suppress the second or third row if it is the same as the previous one?

At first I tried using variables, but then I found that you can't change variable values.

<xsl:variable name="newcust" select="CUST"/>
<xsl:variable name="cust"/>
<xsl:if test="$cust!=$newcust">

Is there another way?

Thanks,

Jens

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


Current Thread