jackrabbit-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Alex Parvulescu (Updated) (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (JCR-3219) regression with self-join queries
Date Fri, 03 Feb 2012 13:53:53 GMT

     [ https://issues.apache.org/jira/browse/JCR-3219?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Alex Parvulescu updated JCR-3219:
---------------------------------

    Attachment: JCR-3219-test.patch

I'm having some trouble reproducing this issue. 
I'm using trunk as a reference.

I've attached a unit-test, it goes into the jackrabbit-jcr2spi module. It only logs the nodes
it finds (no asserts yet), but I only see 2 nodes returned from the query, not 1 or 3.

Can you take a look and tell me what you think?
Maybe I missed something trying to reproduce the error.

It is really good to submit parts of code that can illustrate what you are doing&seeing,
thanks for taking the time to do that.
In the future, I think a complete unit test will help even more with reproducing and fixing
the issue.

                
> regression with self-join queries
> ---------------------------------
>
>                 Key: JCR-3219
>                 URL: https://issues.apache.org/jira/browse/JCR-3219
>             Project: Jackrabbit Content Repository
>          Issue Type: Bug
>          Components: jackrabbit-jcr-server, query, sql
>            Reporter: David Buchmann
>            Priority: Minor
>         Attachments: JCR-3219-test.patch
>
>
> affects version 2.3.7
> running a query that joins on the same node type against 2.3.6 returns 1 result, while
running it against 2.3.7 returns the same node 3 times. if i join two different node types,
i get only one result row...
> to reproduce: in my repository, i have 2 unstructured nodes with the same jcr:mimeType
and one of them having the field zeronumber with value 0.
>             QueryManager qm = s.getWorkspace().getQueryManager();
>             Query q = qm.createQuery("SELECT data.zeronumber FROM [nt:unstructured] AS
data INNER JOIN [nt:unstructured] AS second ON data.[jcr:mimeType] = second.[jcr:mimeType]
WHERE data.zeronumber = 0", Query.JCR_JQOM);
>             QueryResult r = q.execute();
>             RowIterator i = r.getRows();
>             while (i.hasNext()) {
>                 Row n = i.nextRow();
>                 System.out.println(n.getPath("data"));
>             }
> jukka suspects this could be introduced by JCR-3198

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message