Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

single quotes in xpath expression throw an error #3

Open
sputnick-dev opened this issue Dec 8, 2015 · 0 comments
Open

single quotes in xpath expression throw an error #3

sputnick-dev opened this issue Dec 8, 2015 · 0 comments

Comments

@sputnick-dev
Copy link
Owner

Ex:

$ saxon-lint --verbose --xpath "/a//b[contains(., '3')]/text()" examples/XPath/001.xml
::1+java -cp /home/sputnick/github/saxon-lint/lib/saxon9he.jar net.sf.saxon.Query '!encoding=utf-8' '!indent=no' -quit:on '!item-separator=
' -s:examples/XPath/001.xml '-qs:/a//b[contains(., 3)]/text()'
Error on line 1 
  XPTY0004: Required item type of second argument of contains() is xs:string; supplied value
  has item type xs:integer
Static error(s) in query

If I invert shell quotes, this will works.

Nested quotes is a pain at this level. If anyone knows, feel free to tell me where to search.

My best bet (I hope) is to rewrite some code using perl's Java_Inline

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant