Re: [xsl] Grouping upon various attribute values

Subject: Re: [xsl] Grouping upon various attribute values
From: Florent Georges <darkman_spam@xxxxxxxx>
Date: Thu, 17 Aug 2006 00:53:03 +0200 (CEST)
David Carlisle wrote:

> <xsl:function name="f:key">
>   <xsl:param name="nodes" as="item()*"/>
>   <xsl:value-of separator="|">
>   <xsl:perform-sort select="$nodes">
>   <xsl:sort select="name()"/>
>   </xsl:perform-sort>
>   </xsl:value-of>
> </xsl:function>

  That requires that name() will always return the same string for two
nodes with the same name (same namespace URI and same local part name),
which is not guaranted.  IMHO you need, as Mike proposed it, the two

    <xsl:perform-sort select="$nodes">
      <xsl:sort select="namespace-uri()"/>
      <xsl:sort select="local-name()"/>



 uncompressed/chunked Wed Aug 16 22:13:41 GMT 2006 
Dicouvrez un nouveau moyen de poser toutes vos questions quelque soit le sujet ! 
Yahoo! Questions/Riponses pour partager vos connaissances, vos opinions et vos expiriences. 

Current Thread