Re: [xsl] max value

Subject: Re: [xsl] max value
From: Mike Brown <mike@xxxxxxxx>
Date: Tue, 11 Dec 2001 19:04:43 -0700 (MST)
Charly wrote:
> Thanks Mark,
> I still have a problem with the last(), after I do the sort the last doesn't
> give the last position anymore .

position() and last() should be giving you the info relative to the
sorted set. In the example you're going with, the last node should be
the one with the max value. If it is not, then your XSLT processor is
in violation of http://www.w3.org/TR/xslt#sorting which says

  "When a template is instantiated by xsl:apply-templates and
  xsl:for-each, the current node list list consists of the complete
  list of nodes being processed in sorted order."

...and http://www.w3.org/TR/xslt#section-Expressions explains that the
current node list determines the context as used by the XPath functions
such as last().

   - Mike
____________________________________________________________________________
  mike j. brown, fourthought.com  |  xml/xslt: http://skew.org/xml/
  denver/boulder, colorado, usa   |  personal: http://hyperreal.org/~mike/

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


Current Thread
  • RE: [xsl] max value, (continued)
    • Jeff Beadle - Tue, 11 Dec 2001 09:21:04 -0500
      • Charly - Tue, 11 Dec 2001 11:01:44 -0800
    • Mark Miller - Tue, 11 Dec 2001 08:20:08 -0800 (PST)
      • Charly - Tue, 11 Dec 2001 16:36:48 -0800
        • Mike Brown - Tue, 11 Dec 2001 19:04:43 -0700 (MST) <=
        • Charly - Wed, 12 Dec 2001 09:43:21 -0800
    • Jeff Beadle - Tue, 11 Dec 2001 11:27:29 -0500