diff options
author | unknown <sanja@montyprogram.com> | 2014-03-07 13:57:07 +0200 |
---|---|---|
committer | unknown <sanja@montyprogram.com> | 2014-03-07 13:57:07 +0200 |
commit | 321ff25f3d419bc1a1fae2390450d1b4db30b64c (patch) | |
tree | b67582cb1540d4174936149df2f103507bd7a74b /mysql-test/t | |
parent | 1f2ef5740360148961151a71603faae497919aa6 (diff) | |
download | mariadb-git-321ff25f3d419bc1a1fae2390450d1b4db30b64c.tar.gz |
MDEV-5740: Assertion `!derived->first_select()->exclude_from_table_unique_test || derived->outer_select()-> exclude_from_table_unique_test' failed on 2nd execution of PS with derived_merge
Do not check tables of executed units.
Debug info about stages of derived tables execution added.
Diffstat (limited to 'mysql-test/t')
-rw-r--r-- | mysql-test/t/derived_view.test | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/mysql-test/t/derived_view.test b/mysql-test/t/derived_view.test index 61e11cebad4..de08b1c4d0d 100644 --- a/mysql-test/t/derived_view.test +++ b/mysql-test/t/derived_view.test @@ -1704,6 +1704,33 @@ ORDER BY gallery_name ASC drop table galleries, pictures; --echo # +--echo # MDEV-5740: Assertion +--echo #`!derived->first_select()->exclude_from_table_unique_test || +--echo #derived->outer_select()-> exclude_from_table_unique_test' +--echo #failed on 2nd execution of PS with derived_merge +--echo # + +set @save_optimizer_switch5740=@@optimizer_switch; +SET optimizer_switch = 'derived_merge=on'; + +CREATE TABLE t1 (a INT); +INSERT INTO t1 VALUES (1),(2); +CREATE TABLE t2 (b INT); +INSERT INTO t2 VALUES (3),(4); + +PREPARE stmt FROM ' + INSERT INTO t1 SELECT * FROM t2 UNION SELECT * FROM (SELECT * FROM t1) AS sq +'; +EXECUTE stmt; +select * from t1; +EXECUTE stmt; +select * from t1; +deallocate prepare stmt; + +drop table t1,t2; +set optimizer_switch=@save_optimizer_switch5740; + +--echo # --echo # end of 5.3 tests --echo # |