Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"(TRUE OR <Exp>) AND <Exp>" is evaluated incorrectly #3733

Closed
monetdb-team opened this issue Nov 30, 2020 · 0 comments
Closed

"(TRUE OR <Exp>) AND <Exp>" is evaluated incorrectly #3733

monetdb-team opened this issue Nov 30, 2020 · 0 comments
Labels
bug Something isn't working major SQL

Comments

@monetdb-team
Copy link

Date: 2015-06-02 21:15:07 +0200
From: Marvin Wang <>
To: SQL devs <>
Version: 11.19.11 (Oct2014-SP3)
CC: @njnes

Last updated: 2015-08-28 13:42:08 +0200

Comment 20902

Date: 2015-06-02 21:15:07 +0200
From: Marvin Wang <>

User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.10; rv:37.0) Gecko/20100101 Firefox/37.0
Build Identifier:

create table test (c1 int);
insert into test values(1);

SELECT * FROM test WHERE (true OR c1 = 3) AND c1 = 2; /* should return nothing*/

Reproducible: Always

Steps to Reproduce:

create table test (c1 int);
insert into test values(1);

SELECT * FROM test WHERE (true OR c1 = 3) AND c1 = 2; /* should return nothing*/

Actual Results:

return rows that should not match

Expected Results:

should return nothing

Comment 20907

Date: 2015-06-07 14:11:32 +0200
From: MonetDB Mercurial Repository <>

Changeset bdb78936d2ac made by Niels Nes niels@cwi.nl in the MonetDB repo, refers to this bug.

For complete details, see http//devmonetdborg/hg/MonetDB?cmd=changeset;node=bdb78936d2ac

Changeset description:

fixed bug #3733, ie handle (constant (true/false) or predicate) expressions better.

Comment 20908

Date: 2015-06-07 14:13:10 +0200
From: @njnes

fixed by handling or expressions with constants better

Comment 21203

Date: 2015-08-28 13:42:08 +0200
From: @sjoerdmullender

Jul2015 has been released.

@monetdb-team monetdb-team added bug Something isn't working major SQL labels Nov 30, 2020
@sjoerdmullender sjoerdmullender added this to the Ancient Release milestone Feb 7, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working major SQL
Projects
None yet
Development

No branches or pull requests

2 participants