mirror of
https://github.com/MariaDB/server.git
synced 2025-07-30 16:24:05 +03:00
fixed cleanup of result object of subqueries. (BUG#8125)
mysql-test/r/subselect.result: cleaning up of results of subselects test mysql-test/t/subselect.test: cleaning up of results of subselects test sql/item_subselect.cc: call result object cleupup on engine cleunup sql/sql_class.cc: added cleanup of select_max_min_finder_subselect sql/sql_class.h: added cleanup of select_max_min_finder_subselect
This commit is contained in:
@ -2196,3 +2196,15 @@ ERROR 42S22: Reference 'xx' not supported (forward reference in item list)
|
||||
select 1 = ALL (select 1 from t1 where 1 = xx ), 1 as xx from DUAL;
|
||||
ERROR 42S22: Reference 'xx' not supported (forward reference in item list)
|
||||
drop table t1;
|
||||
CREATE TABLE `t1` ( `a` char(3) NOT NULL default '', `b` char(3) NOT NULL default '', `c` char(3) NOT NULL default '', PRIMARY KEY (`a`,`b`,`c`)) ENGINE=InnoDB;
|
||||
CREATE TABLE t2 LIKE t1;
|
||||
INSERT INTO t1 VALUES (1,1,1);
|
||||
INSERT INTO t2 VALUES (1,1,1);
|
||||
PREPARE my_stmt FROM "SELECT t1.b, count(*) FROM t1 group by t1.b having
|
||||
count(*) > ALL (SELECT COUNT(*) FROM t2 WHERE t2.a=1 GROUP By t2.b)";
|
||||
EXECUTE my_stmt;
|
||||
b count(*)
|
||||
EXECUTE my_stmt;
|
||||
b count(*)
|
||||
deallocate prepare my_stmt;
|
||||
drop table t1,t2;
|
||||
|
Reference in New Issue
Block a user