1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-07-30 19:03:16 +03:00

Fix a problem with handling expressions like "(col IS NULL AND <expr1>) OR col == NULL" in WHERE clauses.

FossilOrigin-Name: 40852ca8e215e51f63652a67817361b835b6fbbff7f66af50089af91007505f1
This commit is contained in:
dan
2021-04-10 14:49:45 +00:00
parent 050611a79b
commit 677e62aacd
4 changed files with 22 additions and 9 deletions

View File

@ -97,4 +97,16 @@ do_execsql_test 2.1 {
SELECT * FROM (SELECT a, b FROM t1) LEFT JOIN t3 ON a IS NULL;
}
#-------------------------------------------------------------------------
reset_db
do_execsql_test 3.0 {
CREATE TABLE t0(c0 PRIMARY KEY);
INSERT INTO t0(c0) VALUES (0);
}
do_execsql_test 3.1 {
SELECT * FROM t0 WHERE ((c0 NOT NULL) AND 1) OR (c0 == NULL);
} {0}
finish_test