Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
MariaDB
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
1317dd5a
Commit
1317dd5a
authored
Nov 15, 2002
by
ram@mysql.r18.ru
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
test for NULL processing has been added
parent
5ce8b773
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
21 additions
and
0 deletions
+21
-0
mysql-test/r/heap_btree.result
mysql-test/r/heap_btree.result
+14
-0
mysql-test/t/heap_btree.test
mysql-test/t/heap_btree.test
+7
-0
No files found.
mysql-test/r/heap_btree.result
View file @
1317dd5a
...
...
@@ -213,6 +213,20 @@ a b
INSERT INTO t1 VALUES (1,3);
Duplicate entry '3' for key 1
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;
INSERT into t1 values (1),(2),(3),(4),(5),(6),(7),(8),(9),(10),(11);
DELETE from t1 where a < 100;
...
...
mysql-test/t/heap_btree.test
View file @
1317dd5a
...
...
@@ -137,6 +137,13 @@ SELECT * FROM t1 WHERE b<=>NULL;
INSERT
INTO
t1
VALUES
(
1
,
3
);
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
#
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment