mirror of
https://github.com/MariaDB/server.git
synced 2025-07-30 16:24:05 +03:00
fixed joincleunup to avoid double deletin tables, and too earlyfull cleanup in case of EXPLAIN
fixed cleunup of TMP_TABLE_PARAM (BUG#6406) mysql-test/r/subselect.result: primary query with temporary table and subquery with groupping mysql-test/t/subselect.test: primary query with temporary table and subquery with groupping sql/sql_class.h: fixed cleunup of TMP_TABLE_PARAM sql/sql_select.cc: uncacheable test made simplier fixed joincleunup to avoid double deletin tables, and too earlyfull cleanup in case of EXPLAIN
This commit is contained in:
@ -1991,3 +1991,15 @@ ac
|
||||
NULL
|
||||
drop tables t1,t2;
|
||||
set @got_val= (SELECT 1 FROM (SELECT 'A' as my_col) as T1 ) ;
|
||||
create table t1 (a int, b int);
|
||||
create table t2 (a int, b int);
|
||||
insert into t1 values (1,1),(1,2),(1,3),(2,4),(2,5);
|
||||
insert into t2 values (1,3),(2,1);
|
||||
select distinct a,b, (select max(b) from t2 where t1.b=t2.a) from t1 order by t1.b;
|
||||
a b (select max(b) from t2 where t1.b=t2.a)
|
||||
1 1 3
|
||||
1 2 1
|
||||
1 3 NULL
|
||||
2 4 NULL
|
||||
2 5 NULL
|
||||
drop table t1, t2;
|
||||
|
Reference in New Issue
Block a user