Project

Profile

Help

XPath 3.0 vs. XSLT 3.0

Added by Christopher J Dev about 7 years ago

Hello,

I received the following error message when I tried implementing the path() function.

Could not create transformer based on defined xslt. Reason: Failed creating transformer. Root Cause: 'System function path#1 is not available with this host language/version'

We use Saxonica's Home Edition which supports XSLT v. 2.0. Saxonica's documentation states the HE includes support to Xpath 3.0 and even Xpath 3.1, but not XSLT 3.0.

Am I obliged to use a XSLT 3.0, if I want to use a function supported only in XPath 3.0?

Is path()/path(node) considered a higher order function?

What setting do I need to set in order to start using the path() function with XSLT 2.0, if this is possible?

Any advice would be greatly appreciated. Have a great day.


Replies (3)

Please register to reply

RE: XPath 3.0 vs. XSLT 3.0 - Added by Michael Kay about 7 years ago

The XSLT processor available in Saxon-HE conforms to the XSLT 2.0 recommendation at the basic conformance level (plus some optional features such as serialization and XPath 1.0 backwards compatibility). XSLT 2.0 conformance requires XPath 2.0 conformance, and this does not allow functions in the standard function namespace (such as fn:path) that are not defined in the 2.0 specifications. XSLT 2.0 processors are allowed, however, to provide additional functions in other namespaces, so new functions such as the "math" functions have been provided where the conformance rules allow it.

XPath 3.0/3.1 features are available in Saxon-HE for free-standing XPath, but not for XPath-within-XSLT.

I'm sorry this is all so confusing; it's largely because we adopted a policy of putting functionality into Saxon-HE only when the W3C specs are finalized, and the XSLT 3.0 spec was lagging behind the XPath 3.1 spec.

The good news is that this is a transitional situation. The plan is that in Saxon 9.8, the HE product will include fully conformant XSLT 3.0, XPath 3.1, and XQuery 3.1 processors at the basic conformance level.

RE: XPath 3.0 vs. XSLT 3.0 - Added by Christopher J Dev about 7 years ago

Thank you so much for your detailed answer. Have a great day.

On 9 May 2017 at 23:32, Saxonica Developer Community wrote:

RE: XPath 3.0 vs. XSLT 3.0 - Added by Christopher J Dev about 7 years ago

Thank you so much for your detailed answer. Have a great day.

    (1-3/3)

    Please register to reply