jackrabbit-oak-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Chetan Mehrotra (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (OAK-3013) SQL2 query with union, limit and offset can return invalid results
Date Thu, 09 Jul 2015 08:36:04 GMT

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

Chetan Mehrotra updated OAK-3013:
---------------------------------
    Labels: candidate_oak_1_0 candidate_oak_1_2  (was: )

> SQL2 query with union, limit and offset can return invalid results
> ------------------------------------------------------------------
>
>                 Key: OAK-3013
>                 URL: https://issues.apache.org/jira/browse/OAK-3013
>             Project: Jackrabbit Oak
>          Issue Type: Bug
>          Components: query
>            Reporter: Teodor Rosu
>            Assignee: Amit Jain
>              Labels: candidate_oak_1_0, candidate_oak_1_2
>             Fix For: 1.3.2
>
>         Attachments: OAK-3013-fix.patch, OAK-3013-test.patch
>
>
> when using order, limit and offset and a SQL2 query that contains an union of two subqueries
that have common results can return invalid results
> Example: assuming content tree /test/a/b/c/d/e exists
> {code:sql}
> SELECT [jcr:path] FROM [nt:base] AS a WHERE ISDESCENDANTNODE(a, '/test') UNION SELECT
[jcr:path] FROM [nt:base] AS a WHERE ISDESCENDANTNODE(a, '/test')" ORDER BY [jcr:path]
> {code}
> with limit=3 and offset 2 returns only one row ( instead of 3 )
> the correct result set is
> {noformat}
> /test/a/b/c
> /test/a/b/c/d
> /test/a/b/c/d/e
> {noformat}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message