diff options
author | Sergei Golubchik <serg@mariadb.org> | 2017-09-16 00:21:22 +0200 |
---|---|---|
committer | Sergei Golubchik <serg@mariadb.org> | 2017-09-18 10:40:26 +0200 |
commit | 1fce3680899e601440be21b4c9840826e0318656 (patch) | |
tree | 653ba77eb51e35a80a991d76a6d0c77093d5aa13 /mysql-test | |
parent | 7e56e9ea774a8f7e6e2f0327e8f16d1c3c0f5be9 (diff) | |
download | mariadb-git-1fce3680899e601440be21b4c9840826e0318656.tar.gz |
MDEV-13636 ALTER TABLE ... DELAY_KEY_WRITE=1 creates table copy for MyISAM table with DATA DIRECTORY/INDEX DIRECTORY options
correct detection of changes in DATA/INDEX DIRECTORY
Diffstat (limited to 'mysql-test')
-rw-r--r-- | mysql-test/r/symlink.result | 12 | ||||
-rw-r--r-- | mysql-test/t/symlink.test | 25 |
2 files changed, 37 insertions, 0 deletions
diff --git a/mysql-test/r/symlink.result b/mysql-test/r/symlink.result index 803b43dec87..63fc37300b2 100644 --- a/mysql-test/r/symlink.result +++ b/mysql-test/r/symlink.result @@ -227,3 +227,15 @@ DROP DATABASE x; CREATE TABLE test.t1(id INT(11)) ENGINE MYISAM DATA DIRECTORY "MYSQLTEST_VARDIR/tmp"; DROP TABLE test.t1; +use test; +create table t1(c1 int, c2 int, c3 varchar(100)) engine=MyISAM data directory='MYSQL_TMP_DIR' index directory = 'MYSQL_TMP_DIR'; +insert t1 values (1,2,3), (2,3,4), (3,4,5), (4,5,6), (5,6,7), (6,7,8), (7,8,9); +alter online table t1 delay_key_write=1; +show create table t1; +Table Create Table +t1 CREATE TABLE `t1` ( + `c1` int(11) DEFAULT NULL, + `c2` int(11) DEFAULT NULL, + `c3` varchar(100) DEFAULT NULL +) ENGINE=MyISAM DEFAULT CHARSET=latin1 DELAY_KEY_WRITE=1 DATA DIRECTORY='MYSQL_TMP_DIR/' INDEX DIRECTORY='MYSQL_TMP_DIR/' +drop table t1; diff --git a/mysql-test/t/symlink.test b/mysql-test/t/symlink.test index e17ea07ca3c..cf95d4cb938 100644 --- a/mysql-test/t/symlink.test +++ b/mysql-test/t/symlink.test @@ -316,3 +316,28 @@ eval CREATE TABLE test.t1(id INT(11)) ENGINE MYISAM DATA DIRECTORY "$MYSQLTEST_VARDIR/tmp"; DROP TABLE test.t1; +use test; + +# +# End of 5.5 tests +# + +# +# End of 10.0 tests +# + +# +# MDEV-13636 ALTER TABLE ... DELAY_KEY_WRITE=1 creates table copy for MyISAM table with DATA DIRECTORY/INDEX DIRECTORY options +# +replace_result $MYSQL_TMP_DIR MYSQL_TMP_DIR; +eval +create table t1(c1 int, c2 int, c3 varchar(100)) engine=MyISAM data directory='$MYSQL_TMP_DIR' index directory = '$MYSQL_TMP_DIR'; +insert t1 values (1,2,3), (2,3,4), (3,4,5), (4,5,6), (5,6,7), (6,7,8), (7,8,9); +alter online table t1 delay_key_write=1; +replace_result $MYSQL_TMP_DIR MYSQL_TMP_DIR; +show create table t1; +drop table t1; + +# +# End of 10.1 tests +# |