summaryrefslogtreecommitdiff
path: root/mysql-test/t/heap_btree.test
diff options
context:
space:
mode:
Diffstat (limited to 'mysql-test/t/heap_btree.test')
-rw-r--r--mysql-test/t/heap_btree.test21
1 files changed, 20 insertions, 1 deletions
diff --git a/mysql-test/t/heap_btree.test b/mysql-test/t/heap_btree.test
index fb715fccefe..71743d0d850 100644
--- a/mysql-test/t/heap_btree.test
+++ b/mysql-test/t/heap_btree.test
@@ -165,6 +165,26 @@ SELECT * from t1;
DROP TABLE t1;
#
+# Bug #9719: problem with delete
+#
+
+create table t1(a int not null, key using btree(a)) engine=heap;
+insert into t1 values (2), (2), (2), (1), (1), (3), (3), (3), (3);
+select a from t1 where a > 2;
+delete from t1 where a < 4;
+select a from t1;
+insert into t1 values (2), (2), (2), (1), (1), (3), (3), (3), (3);
+select a from t1 where a > 4;
+delete from t1 where a > 4;
+select a from t1;
+select a from t1 where a > 3;
+delete from t1 where a >= 2;
+select a from t1;
+drop table t1;
+
+--echo End of 4.1 tests
+
+#
# BUG#18160 - Memory-/HEAP Table endless growing indexes
#
CREATE TABLE t1(val INT, KEY USING BTREE(val)) ENGINE=memory;
@@ -184,4 +204,3 @@ CREATE TABLE t1 (a INT, UNIQUE USING BTREE(a)) ENGINE=MEMORY;
INSERT INTO t1 VALUES(NULL),(NULL);
DROP TABLE t1;
-# End of 4.1 tests