You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@calcite.apache.org by "Julian Hyde (JIRA)" <ji...@apache.org> on 2016/11/20 22:46:58 UTC
[jira] [Updated] (CALCITE-1497) Infer IS NOT NULL, and project
predicates
[ https://issues.apache.org/jira/browse/CALCITE-1497?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Julian Hyde updated CALCITE-1497:
---------------------------------
Summary: Infer IS NOT NULL, and project predicates (was: Invalid implications)
> Infer IS NOT NULL, and project predicates
> -----------------------------------------
>
> Key: CALCITE-1497
> URL: https://issues.apache.org/jira/browse/CALCITE-1497
> Project: Calcite
> Issue Type: Bug
> Reporter: Julian Hyde
> Assignee: Julian Hyde
> Fix For: 1.11.0
>
>
> RexImplicationChecker makes some mistakes when OR is on the left-hand size or AND is on the right-hand side. The following 3 tests should all succeed, but all currently give the wrong result. I intend to check in the tests with my fix for CALCITE-1483 (coming soon, currently in my branch https://github.com/julianhyde/calcite/tree/1483-not-in-not-null).
> {code}
> // "s is not null or i = 5" does not imply "s is not null"
> f.checkNotImplies(f.or(sIsNotNull, iEq5), sIsNotNull);
> // "s is not null" implies "s is not null or i = 5"
> f.checkImplies(sIsNotNull, f.or(sIsNotNull, iEq5));
> // "s is not null" implies "i = 5 or s is not null"
> f.checkImplies(sIsNotNull, f.or(iEq5, sIsNotNull));
> {code}
> [~amargoor], Can you comment on these?
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)