RE: grouping (was: if or template?)

Subject: RE: grouping (was: if or template?)
From: Kay Michael <Michael.Kay@xxxxxxx>
Date: Mon, 8 May 2000 11:54:10 +0100
> I want to then display the Tracker_ID if it is unique followed by all the
data for
> the specific tracker. 

A FAQ: use something like
<xsl:for-each select="//tracker-id[not(.=preceding::tracker-id)]">

This is the traditional solution; Steve Muench has just told me about a
brilliant alternative using keys:

<xsl:key name="tid" use="tracker-id" select="."/>

<xsl:for-each
select="//tracker-id[generate-id(.)=generate-id(key('tid',.)[1])]">

I hope Steve will forgive me for announcing this discovery before he does,
I'm quite excited by it because it gives much better performance.

Mike Kay


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


Current Thread