You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@xmlbeans.apache.org by "Radu Preotiuc-Pietro (JIRA)" <xm...@xml.apache.org> on 2008/04/08 00:55:26 UTC

[jira] Created: (XMLBEANS-369) selectPath with XMLBeans engine returns incorrect results

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: dev-unsubscribe@xmlbeans.apache.org
For additional commands, e-mail: dev-help@xmlbeans.apache.org


[jira] Resolved: (XMLBEANS-369) selectPath with XMLBeans engine returns incorrect results

Posted by "Cezar Andrei (JIRA)" <xm...@xml.apache.org>.
     [ https://issues.apache.org/jira/browse/XMLBEANS-369?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Cezar Andrei resolved XMLBEANS-369.
-----------------------------------

    Resolution: Fixed

Fixed with rev 649251

> 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: dev-unsubscribe@xmlbeans.apache.org
For additional commands, e-mail: dev-help@xmlbeans.apache.org