[xquery-talk] Question on expected XQuery return per
standards
G. Ken Holman
gkholman at CraneSoftwrights.com
Sat Mar 28 17:05:00 PST 2009
At 2009-03-28 16:23 +0100, Geert Josten wrote:
>Hi Michael,
>...
> <set1><xsl:value-of select="
> /descendant-or-self::node()/p[position() = 2] "/></set1>,
>...
> <set2><xsl:value-of select=" //p[position() = 2] "/></set2>,
>...
> <set3><xsl:value-of select=" /descendant-or-self::node()/p[2] "/></set3>,
>...
> <set4><xsl:value-of select=" //p[2] "/></set4>,
>...
>But with version 1.0 even Saxon was strangely enough returning p2 only..
Not strange at all! You are using <xsl:value-of/> which returns the
first of the set addressed when using XSLT 1.0. Try using
<xsl:copy-of/> and then you will get a true reading.
I hope this helps.
. . . . . . . . . . Ken
--
XQuery/XSLT/XSL-FO training in Los Angeles (New dates!) 2009-06-08
Training tools: Comprehensive interactive XSLT/XPath 1.0/2.0 video
Video lesson: http://www.youtube.com/watch?v=PrNjJCh7Ppg&fmt=18
Video overview: http://www.youtube.com/watch?v=VTiodiij6gE&fmt=18
G. Ken Holman mailto:gkholman at CraneSoftwrights.com
Crane Softwrights Ltd. http://www.CraneSoftwrights.com/q/
Male Cancer Awareness Nov'07 http://www.CraneSoftwrights.com/q/bc
Legal business disclaimers: http://www.CraneSoftwrights.com/legal
More information about the talk
mailing list