diff options
author | Sergei Golubchik <sergii@pisem.net> | 2012-06-04 17:26:11 +0200 |
---|---|---|
committer | Sergei Golubchik <sergii@pisem.net> | 2012-06-04 17:26:11 +0200 |
commit | 3e3606d21deec2a7508d47740ab7a7a7f5b9b698 (patch) | |
tree | 5e041eb2fc7ca4f15ff97bfc3dba62840ab802fc /mysql-test/t/index_merge_innodb.test | |
parent | afedd72e225654225b20a91b072b012e4c57a9d4 (diff) | |
parent | 25ada13db06d06050f0361bc434fe2b58303b5f2 (diff) | |
download | mariadb-git-3e3606d21deec2a7508d47740ab7a7a7f5b9b698.tar.gz |
merge with 5.3.
Take only test cases from MDEV-136 Non-blocking "set read_only"
Diffstat (limited to 'mysql-test/t/index_merge_innodb.test')
-rw-r--r-- | mysql-test/t/index_merge_innodb.test | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/mysql-test/t/index_merge_innodb.test b/mysql-test/t/index_merge_innodb.test index ca6ada7fc6f..0fd3c54c787 100644 --- a/mysql-test/t/index_merge_innodb.test +++ b/mysql-test/t/index_merge_innodb.test @@ -124,5 +124,38 @@ WHERE v1 IN ('f', 'd', 'h', 'u' ) AND i = 2; DROP TABLE t1; +--echo # +--echo # BUG#1006164: Multi-table DELETE that uses innodb + index_merge/intersect may fail to delete rows +--echo # + +create table t0(a int); +insert into t0 values (0),(1),(2),(3),(4),(5),(6),(7),(8),(9); + +create table t1 ( + pk int auto_increment, + zone_id int, + modified tinyint, + primary key(pk), + key (zone_id), + key (modified) +) engine=innodb; + +insert into t1 (zone_id, modified) select 0,0 from t0 A, t0 B, t0 C, t0 D; +update t1 set zone_id=487, modified=9 where pk=7259; +update t1 set zone_id=487, modified=9 where pk=7260; +update t1 set zone_id=830, modified=9 where pk=8434; +update t1 set zone_id=830, modified=9 where pk=8435; +update t1 set zone_id=830, modified=9 where pk=8436; +update t1 set zone_id=830, modified=9 where pk=8437; + +select * from t1 where t1.zone_id=830 AND modified=9; +begin; +DELETE t1 FROM t1 WHERE t1.zone_id=830 AND modified=9; +commit; +select * from t1 where t1.zone_id=830 AND modified=9; + +drop table t0, t1; + + set optimizer_switch= @optimizer_switch_save; |