1
0
mirror of https://github.com/MariaDB/server.git synced 2025-12-24 11:21:21 +03:00

BUG#11756869 - 48848: MYISAMCHK DOING SORT RECOVER IN CERTAIN

CASES RESETS DATA POINTER TO SMAL

ISSUE: Myisamchk doing sort recover
       on a table reduces data_file_length.
       Maximum size of data file decreases,
       lesser number of rows are stored.

SOLUTION: Size of data_file_length is
          fixed to the original length.
This commit is contained in:
Ashish Agarwal
2012-02-02 14:19:38 +05:30
3 changed files with 35 additions and 8 deletions

View File

@@ -1663,4 +1663,18 @@ CHECK TABLE t1;
DROP TABLE t1;
SET GLOBAL myisam_use_mmap=default;
--echo #
--echo # BUG 11756869 - 48848: MYISAMCHK DOING SORT RECOVER IN CERTAIN
--echo # CASES RESETS DATA POINTER TO SMAL
--echo #
CREATE TABLE t1(a INT, KEY(a));
ALTER TABLE t1 DISABLE KEYS;
let $MYSQLD_DATADIR= `select @@datadir`;
SET @before:= (SELECT MAX_DATA_LENGTH FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_NAME='t1' AND TABLE_SCHEMA='test');
FLUSH TABLES;
--replace_result $MYSQLD_DATADIR MYSQLD_DATADIR
--exec $MYISAMCHK -sn $MYSQLD_DATADIR/test/t1
SET @after:= (SELECT MAX_DATA_LENGTH FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_NAME='t1' AND TABLE_SCHEMA='test');
SELECT @before=@after;
DROP TABLE t1;
--echo End of 5.1 tests