1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-29 05:21:33 +03:00
This commit is contained in:
Alexey Botchkov
2008-10-27 19:56:43 +04:00
6 changed files with 63 additions and 8 deletions

View File

@ -155,3 +155,18 @@ id select_type table type possible_keys key key_len ref rows filtered Extra
Warnings:
Note 1003 select 1 AS `1` from (select count(distinct `test`.`t1`.`a`) AS `COUNT(DISTINCT t1.a)` from `test`.`t1` join `test`.`t2` group by `test`.`t1`.`a`) `s1`
DROP TABLE t1,t2;
#
# Bug#37870: Usage of uninitialized value caused failed assertion.
#
create table t1 (dt datetime not null);
create table t2 (dt datetime not null);
insert into t1 values ('2001-01-01 1:1:1'), ('2001-01-01 1:1:1');
insert into t2 values ('2001-01-01 1:1:1'), ('2001-01-01 1:1:1');
flush tables;
EXPLAIN SELECT OUTR.dt FROM t1 AS OUTR WHERE OUTR.dt IN (SELECT INNR.dt FROM t2 AS INNR WHERE OUTR.dt IS NULL );
id select_type table type possible_keys key key_len ref rows Extra
1 PRIMARY OUTR ALL NULL NULL NULL NULL 2 Using where
2 DEPENDENT SUBQUERY INNR ALL NULL NULL NULL NULL 2 Using where
SELECT OUTR.dt FROM t1 AS OUTR WHERE OUTR.dt IN (SELECT INNR.dt FROM t2 AS INNR WHERE OUTR.dt IS NULL );
dt
drop tables t1, t2;

View File

@ -3672,6 +3672,8 @@ DROP VIEW v1;
# -- End of test case for Bug#35193.
CREATE VIEW v1 AS SELECT 1;
DROP VIEW v1;
# -----------------------------------------------------------------
# -- End of 5.0 tests.
# -----------------------------------------------------------------

View File

@ -123,4 +123,16 @@ execute s1;
DROP TABLE t1,t2;
--echo #
--echo # Bug#37870: Usage of uninitialized value caused failed assertion.
--echo #
create table t1 (dt datetime not null);
create table t2 (dt datetime not null);
insert into t1 values ('2001-01-01 1:1:1'), ('2001-01-01 1:1:1');
insert into t2 values ('2001-01-01 1:1:1'), ('2001-01-01 1:1:1');
flush tables;
EXPLAIN SELECT OUTR.dt FROM t1 AS OUTR WHERE OUTR.dt IN (SELECT INNR.dt FROM t2 AS INNR WHERE OUTR.dt IS NULL );
SELECT OUTR.dt FROM t1 AS OUTR WHERE OUTR.dt IN (SELECT INNR.dt FROM t2 AS INNR WHERE OUTR.dt IS NULL );
drop tables t1, t2;
# End of 5.0 tests.

View File

@ -3556,6 +3556,15 @@ DROP VIEW v1;
###########################################################################
#
# Bug#39040: valgrind errors/crash when creating views with binlog logging
# enabled
#
# Bug is visible only when running in valgrind with binary logging.
CREATE VIEW v1 AS SELECT 1;
DROP VIEW v1;
--echo # -----------------------------------------------------------------
--echo # -- End of 5.0 tests.
--echo # -----------------------------------------------------------------