selectPath with XMLBeans engine returns incorrect results
---------------------------------------------------------
Key: XMLBEANS-369
URL: https://issues.apache.org/jira/browse/XMLBEANS-369
Project: XMLBeans
Issue Type: Bug
Components: XPath
Affects Versions: Version 2.3
Reporter: Radu Preotiuc-Pietro
Assignee: Cezar Andrei
Fix For: Version 2.3.1
The XML:
<a>
<b>
<c>val1</c>
<d>
<c>val2</c>
</d>
</b>
<c>val3</c>
</a>
If I execute the following XQuery: .//b/c
I would expect one result to come back, however, using xmlbeans 2.3, it seems
to select the val2 c as well!?
The test class:
public class TestSelectPath {
public static void main(String[] args) {
final XmlObject obj =
XmlObject.Factory.parse("<a><b><c>val1</c><d><c>val2</c></d><c>val3</c></a>");
final XmlCursor c = obj.newCursor();
c.selectPath(".//b/c");
System.out.println(c.getSelectionCount());
c.dispose();
}
}
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]