From: Date: May 23 2008 12:35am Subject: bzr commit into MySQL:mysql-6.0-runtime tree (konstantin:2641) Bug#27430 List-Archive: http://lists.mysql.com/commits/46976 X-Bug: 27430 Message-Id: <20080522223534.1E5C333004@vajra.local> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="===============1020410036==" --===============1020410036== MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Content-Disposition: inline #At bzr+ssh://bk-internal.mysql.com/bzrroot/server/mysql-6.0-runtime ------------------------------------------------------------ revno: 2641 revision-id: konstantin@stripped parent: konstantin@stripped committer: Konstantin Osipov branch nick: mysql-6.0-runtime timestamp: Fri 2008-05-23 02:35:19 +0400 message: Bug#27430 "Crash in subquery code when in PS and table DDL changed after PREPARE" Add a test case for the situation with small TDC and many merge children. modified: mysql-test/r/merge.result sp1f-merge.result-20001228015634-pf2nbswryog4ykgcx7icbva7tgga7ppt per-file comments: mysql-test/r/merge.result Update results (Bug#27430) --===============1020410036== MIME-Version: 1.0 Content-Type: text/text/x-diff; charset="us-ascii"; name="patch-2641.diff" Content-Transfer-Encoding: 7bit Content-Disposition: inline === modified file 'mysql-test/r/merge.result' --- a/mysql-test/r/merge.result 2008-05-01 09:34:54 +0000 +++ b/mysql-test/r/merge.result 2008-05-22 22:35:19 +0000 @@ -2022,3 +2022,39 @@ 1 SIMPLE NULL NULL NULL NULL NULL NULL NULL Select tables optimized away DROP TABLE t1, t2, t3, t4; End of 5.1 tests +# +# An additional test case for Bug#27430 Crash in subquery code +# when in PS and table DDL changed after PREPARE +# +# Test merge table with too many merge children. +# +drop table if exists t_parent; +set @save_table_definition_cache=@@global.table_definition_cache; +# +# Set @@global.table_definition_cache to minimum +# +set @@global.table_definition_cache=256; +set @a=null; +# +# Create 256 merge children +# +set @a=concat("create table t_parent (a int) union(", @a, +") insert_method=first engine=mrg_myisam"); +prepare stmt from @a; +execute stmt; +prepare stmt from "select * from t_parent"; +execute stmt; +ERROR HY000: Prepared statement needs to be re-prepared +execute stmt; +ERROR HY000: Prepared statement needs to be re-prepared +execute stmt; +ERROR HY000: Prepared statement needs to be re-prepared +deallocate prepare stmt; +# +# Create merge parent +# +# +# Cleanup +# +drop table t_parent; +set @@global.table_definition_cache=@save_table_definition_cache; --===============1020410036==--