This is the mail archive of the xsl-list@mulberrytech.com mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

RE: sort on more than one element


Put as many <xsl:sort> elements as you need:

<xsl:sort select="col1"/>
<xsl:sort select="col2"/>
...

where the first <xsl:sort> element specifies the primary sort key, the
second specifies the secondary sort key and so on. When the apply-templates
or for-each builds its nodelist, it sorts according to the sort keys; if two
or more nodes have equal weight in the sort, then it should return in
document order.

Hope this helps,

Ben




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

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]