Subject: RE: [xsl] Error in XPath 2.0 expression Too many items From: "Michael Kay" <mike@xxxxxxxxxxxx> Date: Tue, 3 Jan 2006 13:15:29 -0000 |
> Just to speculate some more, I guess you have something like this: > > <xsl:variable name="vCityStateZip"> > <xsl:value-of select="city"/> > <xsl:value-of select="state"/> > <xsl:value-of select="zip"/> > </xsl:variable> > > and you really want: > > <xsl:variable name="vCityStateZip" as="xs:string"> > <xsl:value-of> > <xsl:value-of select="city"/> > <xsl:value-of select="state"/> > <xsl:value-of select="zip"/> > </xsl:value-of> > </xsl:variable> > > The former is sequence of several items, the latter is a > sequence of one item. Actually, the former is a single item: a document node. An xsl:variable with child instructions and no "as" attribute always produces a document node. But IIRC there were reports that an early version of the Altova XSLT 2.0 processor got this wrong. Michael Kay http://www.saxonica.com/
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] Error in XPath 2.0 expres, andrew welch | Thread | Re: [xsl] Error in XPath 2.0 expres, rob Jackson |
RE: [xsl] Error in XPath 2.0 expres, Michael Kay | Date | [xsl] Restricting the scope of prec, Peter Flynn |
Month |