summaryrefslogtreecommitdiff
path: root/mysql-test/r/myisam_debug.result
diff options
context:
space:
mode:
authorSergey Petrunya <psergey@askmonty.org>2009-09-08 00:50:10 +0400
committerSergey Petrunya <psergey@askmonty.org>2009-09-08 00:50:10 +0400
commit29f0dcb56337a3e352ad7a70dcff6b25bb605325 (patch)
tree84935c21dc958724ae7dcbeeca0c0f08986fc430 /mysql-test/r/myisam_debug.result
parent915a624cbcb58a10a2cfb2e2e4fd5029191fa86a (diff)
parent8a2454f8e9fce648272577fcf8006ae6e6806cf9 (diff)
downloadmariadb-git-29f0dcb56337a3e352ad7a70dcff6b25bb605325.tar.gz
Merge MySQL->MariaDB
* Finished Monty and Jani's merge * Some InnoDB tests still fail (because it's old xtradb code run against newer testsuite). They are expected to go after mergning with the latest xtradb.
Diffstat (limited to 'mysql-test/r/myisam_debug.result')
-rw-r--r--mysql-test/r/myisam_debug.result39
1 files changed, 39 insertions, 0 deletions
diff --git a/mysql-test/r/myisam_debug.result b/mysql-test/r/myisam_debug.result
new file mode 100644
index 00000000000..c128bfffce9
--- /dev/null
+++ b/mysql-test/r/myisam_debug.result
@@ -0,0 +1,39 @@
+#
+# BUG#40827 - Killing insert-select to MyISAM can cause table corruption
+#
+CREATE TABLE `t1` (
+`id` BIGINT(20) ,
+`id1` BIGINT(20) AUTO_INCREMENT,
+KEY(id1), KEY(id)
+) ENGINE=MyISAM;
+CREATE TABLE `t2` (
+`id` BIGINT(20) ,
+`id1` BIGINT(20) AUTO_INCREMENT,
+KEY (id1), KEY(id)
+) ENGINE=MyISAM;
+INSERT INTO t2 (id) VALUES (123);
+INSERT INTO t2 (id) SELECT id FROM t2;
+INSERT INTO t2 (id) SELECT id FROM t2;
+INSERT INTO t2 (id) SELECT id FROM t2;
+INSERT INTO t2 (id) SELECT id FROM t2;
+INSERT INTO t2 (id) SELECT id FROM t2;
+INSERT INTO t2 (id) SELECT id FROM t2;
+INSERT INTO t2 (id) SELECT id FROM t2;
+INSERT INTO t2 (id) SELECT id FROM t2;
+INSERT INTO t2 (id) SELECT id FROM t2;
+INSERT INTO t2 (id) SELECT id FROM t2;
+# Switch to insert Connection
+SET SESSION debug='+d,wait_in_enable_indexes';
+# Send insert data
+INSERT INTO t1(id) SELECT id FROM t2;
+# Switch to default Connection
+# Wait for insert data to reach the debug point
+SELECT ID FROM INFORMATION_SCHEMA.PROCESSLIST
+WHERE STATE = 'wait_in_enable_indexes' AND
+INFO = "INSERT INTO t1(id) SELECT id FROM t2"
+INTO @thread_id;
+KILL QUERY @thread_id;
+CHECK TABLE t1;
+Table Op Msg_type Msg_text
+test.t1 check status OK
+DROP TABLE t1,t2;