mirror of
https://github.com/MariaDB/server.git
synced 2025-07-30 16:24:05 +03:00
wl#2126 - ndb - Fix handling of null values wrt read multi range
mysql-test/r/ndb_read_multi_range.result: Add tests of null handling to read_multi mysql-test/t/ndb_read_multi_range.test: Add tests of null handling to read_multi ndb/include/ndbapi/NdbOperation.hpp: Get recattr ndb/include/ndbapi/NdbRecAttr.hpp: Get recattr sql/ha_ndbcluster.cc: Fix handling of null values wrt read multi range sql/ha_ndbcluster.h: Fix handling of null values wrt read multi range
This commit is contained in:
@ -212,3 +212,54 @@ delete from t1 where d in (12,6,7);
|
||||
select * from t1 where d in (12,6,7);
|
||||
a b c d e
|
||||
drop table t1;
|
||||
create table t1 (
|
||||
a int not null primary key,
|
||||
b int,
|
||||
c int,
|
||||
d int,
|
||||
unique index (b),
|
||||
index(c)
|
||||
) engine = ndb;
|
||||
insert into t1 values
|
||||
(1,null,1,1),
|
||||
(2,2,2,2),
|
||||
(3,null,null,3),
|
||||
(4,4,null,4),
|
||||
(5,null,5,null),
|
||||
(6,6,6,null),
|
||||
(7,null,null,null),
|
||||
(8,8,null,null),
|
||||
(9,null,9,9),
|
||||
(10,10,10,10),
|
||||
(11,null,null,11),
|
||||
(12,12,null,12),
|
||||
(13,null,13,null),
|
||||
(14,14,14,null),
|
||||
(15,null,null,null),
|
||||
(16,16,null,null);
|
||||
create table t2 as select * from t1 where a in (5,6,7,8,9,10);
|
||||
select * from t2 order by a;
|
||||
a b c d
|
||||
5 NULL 5 NULL
|
||||
6 6 6 NULL
|
||||
7 NULL NULL NULL
|
||||
8 8 NULL NULL
|
||||
9 NULL 9 9
|
||||
10 10 10 10
|
||||
drop table t2;
|
||||
create table t2 as select * from t1 where b in (5,6,7,8,9,10);
|
||||
select * from t2 order by a;
|
||||
a b c d
|
||||
6 6 6 NULL
|
||||
8 8 NULL NULL
|
||||
10 10 10 10
|
||||
drop table t2;
|
||||
create table t2 as select * from t1 where c in (5,6,7,8,9,10);
|
||||
select * from t2 order by a;
|
||||
a b c d
|
||||
5 NULL 5 NULL
|
||||
6 6 6 NULL
|
||||
9 NULL 9 9
|
||||
10 10 10 10
|
||||
drop table t2;
|
||||
drop table t1;
|
||||
|
Reference in New Issue
Block a user