db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "A B (JIRA)" <j...@apache.org>
Subject [jira] Commented: (DERBY-2526) Wrong results with queries that use the JOIN ... ON syntax to join with views or other non-base table expressions.
Date Thu, 18 Sep 2008 16:18:44 GMT

    [ https://issues.apache.org/jira/browse/DERBY-2526?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12632272#action_12632272

A B commented on DERBY-2526:

> I'll look into backporting this fix to 10.2 and 10.1

For what it's worth, there was another bug in a similar area that also affected 10.1 and 10.2,
namely, DERBY-3023.  One of the comments for that issue includes the following quote:

  "It turns out that the introduction of these invalid predicates stems from a problem that
is almost
  identical to the one described in DERBY-2526. For details please see d2526_v1.html as attached
  to that issue, since pretty much everything in that document applies to this issue, as well."

So I wonder if it'd be worth it to port DERBY-3023 back, as well?  I don't feel strongly about
it, I just figured I'd mention it in case you were interested...

> Wrong results with queries that use the JOIN ... ON syntax to join with views or other
non-base table expressions.
> ------------------------------------------------------------------------------------------------------------------
>                 Key: DERBY-2526
>                 URL: https://issues.apache.org/jira/browse/DERBY-2526
>             Project: Derby
>          Issue Type: Bug
>          Components: SQL
>    Affects Versions:,,,
>            Reporter: Bryan Pendleton
>            Assignee: A B
>             Fix For:,,
>         Attachments: badQuery.log, d2526_v1.html, d2526_v1.patch, d2526_v2.patch, d2526_v2.stat,
derby-2526.sql, DistinctTestNotes.txt, firstTryPatch.diff, goodQuery.log, releaseNote.html,
releaseNote.html, TestDerby.java
> I think both select statements in the attached repro script should return 1 row, but
in fact the first statement returns 1 row and the second returns zero rows.
> The only difference between the two statements is that the columns in the UNION view
are listed in a different order (bvw vs. bvw2).
> This seems like a bug to me; the order of the columns in the view definition shouldn't
matter, should it? 
> As Army noted on the derby-dev list, the fact that this reproduces with 10.0 means that
it is not caused by some of the 10.2 optimizer changes. Something else is going wrong.

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message