Schematron and XPath 2.0 expressions?
Posted: Tue Feb 05, 2013 7:44 pm
Hi again,
Another question relating to Schematron. I have a Schematron schema where I need to use XPath 2.0 in the assert test expressions. In Oxygen Preferences, there is an option under Schematron allowing me to indicate whether to use XPath 1.0 or XPath 2.0. I select the latter, however, when I validate my instance documents, I get an error saying:
"E [ISO Schematron] Failed to compile stylesheet. 1 error detected."
"W [ISO Schematron] Error in expression every $n in tokenize(current(), '\s+') satisfies $n=document('subdir/data.xml')/gc:CodeList/SimpleCodeList/Row/Value[@ColumnRef='name']/SimpleValue: Unexpected token $ beyond end of expression"
If I use XProch and p:validate-with-schematron with same schema, there is no problem/error.
Thanks in advance!
Mats
Another question relating to Schematron. I have a Schematron schema where I need to use XPath 2.0 in the assert test expressions. In Oxygen Preferences, there is an option under Schematron allowing me to indicate whether to use XPath 1.0 or XPath 2.0. I select the latter, however, when I validate my instance documents, I get an error saying:
"E [ISO Schematron] Failed to compile stylesheet. 1 error detected."
"W [ISO Schematron] Error in expression every $n in tokenize(current(), '\s+') satisfies $n=document('subdir/data.xml')/gc:CodeList/SimpleCodeList/Row/Value[@ColumnRef='name']/SimpleValue: Unexpected token $ beyond end of expression"
If I use XProch and p:validate-with-schematron with same schema, there is no problem/error.
Thanks in advance!
Mats