XdmException on XQSharp XPathEvaluate
Posted
by Florian
on Stack Overflow
See other posts from Stack Overflow
or by Florian
Published on 2010-05-05T20:00:16Z
Indexed on
2010/05/05
20:38 UTC
Read the original article
Hit count: 236
I am trying to evaluate a XPathExpression with XQSharp and get the Error:"Type check error. The empty sequence cannot be cast to type 'xs:integer'."
AltovaXMLSpy evaluates it correct as "true".
oXmlDoc.CreateNavigator().XPathEvaluate("root/foo/bar cast as xs:integer lt count(root/blah/blub)", oNamespaseManager).ToString()
This XML looks like this:
<root xmlns:xs="http://www.w3.org/2001/XMLSchema">
<foo>
<bar>0</bar>
</foo>
<blah>
<blub/>
</blah>
</root>
What am I missing?
© Stack Overflow or respective owner