diff options
author | unknown <cmiller@zippy.cornsilk.net> | 2007-04-16 15:00:16 -0400 |
---|---|---|
committer | unknown <cmiller@zippy.cornsilk.net> | 2007-04-16 15:00:16 -0400 |
commit | a318c75af76c8676cfe45dc154685a6e0e283cfa (patch) | |
tree | e68dcf9e4da1e26017147a6a49efedd872c2ac21 | |
parent | d1c5f54ba5420f5b0c286c1ca74abd8989c7cbf9 (diff) | |
download | mariadb-git-a318c75af76c8676cfe45dc154685a6e0e283cfa.tar.gz |
Bug#25347: mysqlcheck -A -r doesn't repair table marked as crashed
Additional changes to test: "flush tables" so that Windows releases
the files.
mysql-test/r/mysqlcheck.result:
Add "flush tables" to get windows to release the files, so that
we can test truncation properly.
mysql-test/t/mysqlcheck.test:
Add "flush tables" to get windows to release the files, so that
we can test truncation properly.
-rw-r--r-- | mysql-test/r/mysqlcheck.result | 27 | ||||
-rw-r--r-- | mysql-test/t/mysqlcheck.test | 8 |
2 files changed, 34 insertions, 1 deletions
diff --git a/mysql-test/r/mysqlcheck.result b/mysql-test/r/mysqlcheck.result index 81a30267e04..1c42b0060f7 100644 --- a/mysql-test/r/mysqlcheck.result +++ b/mysql-test/r/mysqlcheck.result @@ -45,8 +45,33 @@ create database d_bug25347; use d_bug25347; create table t_bug25347 (a int); create view v_bug25347 as select * from t_bug25347; +insert into t_bug25347 values (1),(2),(3); +flush tables; removing and creating -d_bug25347.t_bug25347 OK +d_bug25347.t_bug25347 +error : Incorrect file format 't_bug25347' +insert into t_bug25347 values (4),(5),(6); +ERROR HY000: Incorrect file format 't_bug25347' +d_bug25347.t_bug25347 +warning : Number of rows changed from 0 to 3 +status : OK +insert into t_bug25347 values (7),(8),(9); +select * from t_bug25347; +a +1 +2 +3 +7 +8 +9 +select * from v_bug25347; +a +1 +2 +3 +7 +8 +9 drop view v_bug25347; drop table t_bug25347; drop database d_bug25347; diff --git a/mysql-test/t/mysqlcheck.test b/mysql-test/t/mysqlcheck.test index 5efe6ade6bb..655ff39001c 100644 --- a/mysql-test/t/mysqlcheck.test +++ b/mysql-test/t/mysqlcheck.test @@ -38,11 +38,19 @@ create database d_bug25347; use d_bug25347; create table t_bug25347 (a int); create view v_bug25347 as select * from t_bug25347; +insert into t_bug25347 values (1),(2),(3); +flush tables; --echo removing and creating --remove_file $MYSQLTEST_VARDIR/master-data/d_bug25347/t_bug25347.MYI --write_file $MYSQLTEST_VARDIR/master-data/d_bug25347/t_bug25347.MYI EOF EOF --exec $MYSQL_CHECK --repair --databases d_bug25347 +--error 130 +insert into t_bug25347 values (4),(5),(6); +--exec $MYSQL_CHECK --repair --use-frm --databases d_bug25347 +insert into t_bug25347 values (7),(8),(9); +select * from t_bug25347; +select * from v_bug25347; drop view v_bug25347; drop table t_bug25347; drop database d_bug25347; |