[XSL-LIST Mailing List Archive Home] [By Thread] [By Date]

RE: [xsl] Comparing node for identity using union


Subject: RE: [xsl] Comparing node for identity using union
From: "Michael Kay" <mike@xxxxxxxxxxxx>
Date: Tue, 18 Jan 2005 20:03:06 -0000

> Well, just for the record, i solve my problem, by using 
> 
> <xsl:variable name="snode" select="(//Menu)[position()=$pos]"/>
> 
> instead of
> 
> <xsl:variable name="snode" select="(//Menu)[$pos]"/> 
> 
> A million neurones i burn to reach this solution!!!
> 
> This seems clearly a bug in XSLTProcessor, does anyone knows where can
> i submit this?

Did you show us the declaration of the variable $pos? If it's a string or a
result tree fragment, then the two expressions are not equivalent. They are
only equivalent if it is a number. There is a note in the XSLT 1.0
specification warning you of this.

Michael Kay
http://www.saxonica.com/


Current Thread
Keywords