You are not logged in.
When specifying an Xpath to extract specific data from an XML document you may get a similar error to "XPath failed due to: Cannot compare xs:Qname to xs:String" (The "Qname" may differ). This is because you are trying to do a String comparison to an entity that has been defined with different type, in this case a Qname.
For Example lets say you were trying to ascertain whether or not a mapping with an id = "CollectId3" under the Action "testAction2" existed, you may be tempted to compile an xPath as follows:
/Configuration/Actions/Action[@name='testAction2']//@id='CollectId3'
This would fail with "XPath failed due to: Cannot compare xs:Qname to xs:String" because you have given a String value but the id attribute type is actually a Qname.
To resolve this issue you would need to do the following:
Xpath 1.0
======
/Configuration/Actions/Action[@name='testAction2']//@id=fn:string('CollectId3')
Xpath 2.0 (Not compatible with X-ServiceBroker but can be used in Stylesheets)
======
/Configuration/Actions/Action[@name='testAction2']//@id=fn:QName( 'http://www.sxi.co.za/XMLSchema/Configuration','CollectId3')
Note: If you get a fn: prefix not defined error you will need to add the fn: prefix namespace with the URI "http://www.w3.org/2005/xpath-functions"
Offline