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

Is this a legal XPath Expression?

Subject: Is this a legal XPath Expression?
From: "Phil Gooch" <phil.gooch@xxxxxxxxx>
Date: Wed, 14 Mar 2001 18:37:36 -0000
phil gooch
Hi there

The <xsl:variable> assignment works fine in MSXML3 but not in Saxon 5.51:

<xsl:template match="TR/TD[15]">
		<xsl:variable name="subject"
select=".[not(.=preceding::TR/TD[15]/node())]"/>
		<xsl:if test="$subject !=''">
		<tr>
			<td>
				<a href="{$subject}.html"><xsl:value-of select="$subject"/></a>
			</td>
		</tr>
		</xsl:if>
</xsl:template>

Saxon replies with 'Unexpected token [ beyond end of expression'

If I change the expression to

<xsl:variable name="subject"
select="node()[not(.=preceding::TR/TD[15]/node())]"/>

it works in Saxon.

I understood that . and node() were equivalent.

Thanks

Phil

-----------------------------------------------------------------------
Phil Gooch
XML Analyst

CSW Informatics Ltd
4240 Nash Court
Oxford Business Park South,
Oxford, OX4 2RU, UK
Tel: +44/0 1865 337400
Mobile: +44/0 7951 139 845
Fax: +44/0 1865 337433
Web: http://www.csw.co.uk

'Providing innovative document and information management solutions that are
designed to help our customers operate more efficiently, productively and
profitably.'
-----------------------------------------------------------------------




 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


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-2011 All Rights Reserved.