jackrabbit-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Przemo Pakulski (JIRA)" <j...@apache.org>
Subject [jira] Created: (JCR-591) XPath position function does not work
Date Thu, 12 Oct 2006 23:35:50 GMT
XPath position function does not work

                 Key: JCR-591
                 URL: http://issues.apache.org/jira/browse/JCR-591
             Project: Jackrabbit
          Issue Type: Bug
          Components: query
    Affects Versions: 1.0.1
            Reporter: Przemo Pakulski
            Priority: Minor

Expression with position function are supported in XPath but does not work. 
All rows are returned when equality operator is used.

	public void testXPathPosition() throws Exception {
		Node foo = testRootNode.addNode("name");
		Node bar = testRootNode.addNode("name");

		String xpath = "//name[position()=2]";
		Query q = superuser.getWorkspace().getQueryManager().createQuery(xpath, Query.XPATH);
		QueryResult result = q.execute();
		checkResult(result, 1);
		checkResult(result, new Node[]{bar});

This message is automatically generated by JIRA.
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira


View raw message