test for NULL processing has been added
This commit is contained in:
parent
5ce8b77301
commit
1317dd5a63
@ -213,6 +213,20 @@ a b
|
|||||||
INSERT INTO t1 VALUES (1,3);
|
INSERT INTO t1 VALUES (1,3);
|
||||||
Duplicate entry '3' for key 1
|
Duplicate entry '3' for key 1
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
|
CREATE TABLE t1 (a int, b int, c int, key using BTREE (a, b, c)) type=heap;
|
||||||
|
INSERT INTO t1 VALUES (1, NULL, NULL), (1, 1, NULL), (1, NULL, 1);
|
||||||
|
SELECT * FROM t1 WHERE a=1 and b IS NULL;
|
||||||
|
a b c
|
||||||
|
1 NULL NULL
|
||||||
|
1 NULL 1
|
||||||
|
SELECT * FROM t1 WHERE a=1 and c IS NULL;
|
||||||
|
a b c
|
||||||
|
1 NULL NULL
|
||||||
|
1 1 NULL
|
||||||
|
SELECT * FROM t1 WHERE a=1 and b IS NULL and c IS NULL;
|
||||||
|
a b c
|
||||||
|
1 NULL NULL
|
||||||
|
DROP TABLE t1;
|
||||||
CREATE TABLE t1 (a int not null, primary key using BTREE (a)) type=heap;
|
CREATE TABLE t1 (a int not null, primary key using BTREE (a)) type=heap;
|
||||||
INSERT into t1 values (1),(2),(3),(4),(5),(6),(7),(8),(9),(10),(11);
|
INSERT into t1 values (1),(2),(3),(4),(5),(6),(7),(8),(9),(10),(11);
|
||||||
DELETE from t1 where a < 100;
|
DELETE from t1 where a < 100;
|
||||||
|
@ -137,6 +137,13 @@ SELECT * FROM t1 WHERE b<=>NULL;
|
|||||||
INSERT INTO t1 VALUES (1,3);
|
INSERT INTO t1 VALUES (1,3);
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
|
|
||||||
|
CREATE TABLE t1 (a int, b int, c int, key using BTREE (a, b, c)) type=heap;
|
||||||
|
INSERT INTO t1 VALUES (1, NULL, NULL), (1, 1, NULL), (1, NULL, 1);
|
||||||
|
SELECT * FROM t1 WHERE a=1 and b IS NULL;
|
||||||
|
SELECT * FROM t1 WHERE a=1 and c IS NULL;
|
||||||
|
SELECT * FROM t1 WHERE a=1 and b IS NULL and c IS NULL;
|
||||||
|
DROP TABLE t1;
|
||||||
|
|
||||||
#
|
#
|
||||||
# Test when deleting all rows
|
# Test when deleting all rows
|
||||||
#
|
#
|
||||||
|
Loading…
x
Reference in New Issue
Block a user