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

expressions in the WHERE clause that evaluates incorrectly #4025

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

expressions in the WHERE clause that evaluates incorrectly #4025

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

Comments

@monetdb-team
Copy link

@monetdb-team monetdb-team commented Nov 30, 2020

Date: 2016-06-23 16:03:40 +0200
From: homner
To: SQL devs <>
Version: 11.23.3 (Jun2016)
CC: @njnes

Last updated: 2016-10-13 10:04:26 +0200

Comment 22209

Date: 2016-06-23 16:03:40 +0200
From: homner

User-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/51.0.2704.103 Safari/537.36
Build Identifier:

We found yet another combination of expressions in the WHERE clause that evaluates incorrectly.

Reproducible: Always

Steps to Reproduce:

CREATE TABLE test3 (pid INTEGER);
INSERT INTO test3 VALUES (1);

SELECT t3.pid FROM test3 t3
WHERE FALSE AND (FALSE OR FALSE) OR TRUE

similar to https://www.monetdb.org/bugzilla/show_bug.cgi?id=3851

Actual Results:

+-----+
| pid |
+=====+
+-----+

Expected Results:

+------+
| pid |
+======+
| 1 |
+------+

the same problem with:
FALSE AND (TRUE OR TRUE) OR TRUE
FALSE AND (FALSE OR TRUE) OR TRUE

if you replace the OR operator in the middle expression with AND like (FALSE OR FALSE) -> (FALSE AND FALSE), the expression evaluates correctly.

Comment 22234

Date: 2016-07-05 16:43:54 +0200
From: MonetDB Mercurial Repository <>

Changeset dc3f469aa330 made by Sjoerd Mullender sjoerd@acm.org in the MonetDB repo, refers to this bug.

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

Changeset description:

Added test for bug #4025.

Comment 22286

Date: 2016-08-07 19:29:45 +0200
From: MonetDB Mercurial Repository <>

Changeset ef8b58752be3 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=ef8b58752be3

Changeset description:

fixed bug #4025, ie incorrect handling of boolean expressions

Comment 22287

Date: 2016-08-07 19:49:11 +0200
From: @njnes

fixed bug in or rewrites

Comment 24498

Date: 2016-10-13 10:04:26 +0200
From: @sjoerdmullender

Jun2016-SP2 has been released.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
1 participant