Subject: [xsl] Selecting Maximum Values From: "David B. Bitton" <david@xxxxxxxxxxxxxx> Date: Mon, 18 Mar 2002 17:27:42 -0500 |
I'm doing this: <?xml version="1.0" encoding="UTF-8"?> <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:fo="http://www.w3.org/1999/XSL/Format"> <xsl:template match="/FieldMapLists"> <xsl:for-each select="FieldMapList"> <xsl:sort data-type="number" order="descending" select="sum(StartPos | Size)"/> <xsl:choose> <xsl:when test="position() = 1"> <xsl:value-of select="StartPos + Size"/><br/> </xsl:when> </xsl:choose> </xsl:for-each> </xsl:template> </xsl:stylesheet> I was wondering if there was a simplier way, or is this the way to do it. I'm never sure if I'm doing it the "right" way. :) -- David B. Bitton david@xxxxxxxxxxxxxx Diversa ab illis virtute valemus.
Attachment:
pgp00007.pgp
Description: PGP signature
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
[xsl] HTML ->WML with XSLT, Jacob P. Glenn | Thread | Re: [xsl] Selecting Maximum Values, David Carlisle |
[xsl] HTML ->WML with XSLT, Jacob P. Glenn | Date | Re: [xsl] Selecting Maximum Values, David Carlisle |
Month |