diff options
author | acurtis@xiphis.org <> | 2006-05-09 13:31:46 -0700 |
---|---|---|
committer | acurtis@xiphis.org <> | 2006-05-09 13:31:46 -0700 |
commit | 47e89f208a25652ec93529eb7dc4944ec5a73659 (patch) | |
tree | 1fed1caed61ab2e91c6c91ac94cad060494a7492 /mysql-test/t | |
parent | ec4211923320e398b3ebdef4fdde7f55fe93dd55 (diff) | |
download | mariadb-git-47e89f208a25652ec93529eb7dc4944ec5a73659.tar.gz |
bug#10952
"alter table from MyISAM to MERGE lost data without errors and warnings"
Add new handlerton flag which prevent user from altering table storage
engine to storage engines which would lose data. Both 'blackhole' and
'merge' are marked with the new flag.
Tests included.
Diffstat (limited to 'mysql-test/t')
-rw-r--r-- | mysql-test/t/blackhole.test | 12 | ||||
-rw-r--r-- | mysql-test/t/merge.test | 12 |
2 files changed, 24 insertions, 0 deletions
diff --git a/mysql-test/t/blackhole.test b/mysql-test/t/blackhole.test index e40b84eb5cd..493f74ded3e 100644 --- a/mysql-test/t/blackhole.test +++ b/mysql-test/t/blackhole.test @@ -128,3 +128,15 @@ show binlog events; drop table t1,t2,t3; # End of 4.1 tests + +# +# BUG#10952 - alter table ... lost data without errors and warnings +# +drop table if exists t1; +create table t1 (c char(20)) engine=MyISAM; +insert into t1 values ("Monty"),("WAX"),("Walrus"); +--error 1031 +alter table t1 engine=blackhole; +drop table t1; + +# End of 5.0 tests diff --git a/mysql-test/t/merge.test b/mysql-test/t/merge.test index 060f1ea167b..7ea14a811ed 100644 --- a/mysql-test/t/merge.test +++ b/mysql-test/t/merge.test @@ -379,3 +379,15 @@ check table t1, t2; drop table t1, t2, t3; # End of 4.1 tests + +# +# BUG#10952 - alter table ... lost data without errors and warnings +# +drop table if exists t1; +create table t1 (c char(20)) engine=MyISAM; +insert into t1 values ("Monty"),("WAX"),("Walrus"); +--error 1031 +alter table t1 engine=MERGE; +drop table t1; + +# End of 5.0 tests |