Page 1 of 1

Schematron: Replace on root element not working

Posted: Thu Feb 18, 2016 9:19 am
by Patrik
Applying this (simplified) quick fix causes an error in oXygen:

Code: Select all

<sqf:fix id="test">
<sqf:description>
<sqf:title>replace root element</sqf:title>
</sqf:description>
<sqf:replace match="/*" select="."/>
</sqf:fix>
error:

Code: Select all

Cannot perform the quick fix: Cannot execute operation: Delete Node. Cause: ro.sync.xml.xpath.g: XPath failed due to: Finding root of tree: the context item is absent
Patrik

Re: Schematron: Replace on root element not working

Posted: Thu Feb 18, 2016 10:19 am
by tavy
Hi Patrik,

I added an issue on our issue tracker regarding this problem. It is a particular case and the replace operation needs to be implemented differently.

Best Regards,
Octavian