You are viewing a plain text version of this content. The canonical link for it is here.
Posted to derby-dev@db.apache.org by "Mike Matrigali (JIRA)" <ji...@apache.org> on 2014/10/10 01:05:34 UTC

[jira] [Reopened] (DERBY-6563) NOT elimination for CASE expressions is broken

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

Mike Matrigali reopened DERBY-6563:
-----------------------------------
      Assignee: Mike Matrigali  (was: Knut Anders Hatlen)

reopening for 10.10 backport, temp assigning myself while working on this.

> NOT elimination for CASE expressions is broken
> ----------------------------------------------
>
>                 Key: DERBY-6563
>                 URL: https://issues.apache.org/jira/browse/DERBY-6563
>             Project: Derby
>          Issue Type: Bug
>          Components: SQL
>    Affects Versions: 10.10.2.0
>            Reporter: Knut Anders Hatlen
>            Assignee: Mike Matrigali
>             Fix For: 10.11.1.1
>
>         Attachments: d6563-1a.diff
>
>
> NOT elimination for CASE expressions seems to be broken. Take this example:
> {noformat}
> ij> select * from sysibm.sysdummy1 where not ( case when ibmreqd = 'Y' then true else true end );
> IBM&
> ----
> Y   
> 1 row selected
> {noformat}
> Both branches of the CASE expression evaluate to TRUE, so one would expect the predicate "not ( case ... )" to evaluate to FALSE, and the query should return an empty result.



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