20
# Bug#16532:mysql server assert in debug if table det is removed
24
drop table if exists t1;
26
create TEMPORARY table break_frm(a int) engine=myisam;
27
insert into break_frm values(1);
28
--system rm -f $MYSQLTEST_VARDIR/master-data/test/break_frm.frm
29
--system rm -f $MYSQLTEST_VARDIR/master-data/test/break_frm.dfe
30
--echo "We get an error because the table is in the definition cache"
31
--error ER_TABLE_EXISTS_ERROR
32
create TEMPORARY table break_frm(a int, b int);
33
--echo "Flush the cache and recreate the table anew to be able to drop it"
35
show open tables like "break_frm%";
36
create table break_frm(a int, b int, c int);
37
--echo "Try to select from the table. This should not crash the server"
38
select count(a) from break_frm;
40
--system rm -f $MYSQLTEST_VARDIR/master-data/test/break_frm.*
41
create TEMPORARY table break_frm(a int) engine=myisam;
42
drop table if exists break_frm;