[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: .[predicate] vs self::node()[predicate]- Xalan 2.7

Subject: Re: .[predicate] vs self::node()[predicate]- Xalan 2.7
From: "Imsieke, Gerrit, le-tex" <gerrit.imsieke@xxxxxxxxx>
Date: Wed, 17 Apr 2013 11:27:07 +0200
Re:  .[predicate] vs self::node()[predicate]- Xalan 2.7
On 17.04.2013 11:12, Raimund Kammering wrote:
XSL:
<xsl:template match="entry/sum">
   ...
   <xsl:for-each select=".[starts-with(name,'tdown')]">
   ...
   </xsl:for-each>
   ...
</xsl:template>

Given the structure of your XML document, it looks as if the processor interprets ".[starts-with(name,'tdown')]" as "*[starts-with(name(),'tdown')]".
Except that your original expression cannot match because there is no element called 'name'  you probably wanted to write 'name()'.


If the first hypothesis is correct, it will explain that "self::node()[starts-with(name,'tdown')]" does not match while "child::node()[starts-with(name,'tdown')]" or "*[starts-with(name,'tdown')]" will probably match. All based on the assumption that your XML structure actually looks like the example that you gave.

Gerrit

Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.