summaryrefslogtreecommitdiff
path: root/mysql-test/t/range.test
diff options
context:
space:
mode:
authorunknown <sergefp@mysql.com>2007-03-29 10:35:28 +0400
committerunknown <sergefp@mysql.com>2007-03-29 10:35:28 +0400
commitbedd5b8766a680539f11ee3f437e4ee1d75b8a87 (patch)
tree85dd8c6e2be153b923a960c908402c1bd6c4d5a4 /mysql-test/t/range.test
parentec3de56263e748603b954e29ca35bacb3e386176 (diff)
parent9b358f811b046ce5e188235d7e3d60424d5579e7 (diff)
downloadmariadb-git-bedd5b8766a680539f11ee3f437e4ee1d75b8a87.tar.gz
Merge of BUG#26624 and BUG#26625
mysql-test/r/range.result: Auto merged mysql-test/t/range.test: Auto merged
Diffstat (limited to 'mysql-test/t/range.test')
-rw-r--r--mysql-test/t/range.test32
1 files changed, 32 insertions, 0 deletions
diff --git a/mysql-test/t/range.test b/mysql-test/t/range.test
index 72be4e12c6a..c5e7b899577 100644
--- a/mysql-test/t/range.test
+++ b/mysql-test/t/range.test
@@ -568,6 +568,38 @@ SELECT s.oxid FROM t1 v, t1 s
DROP TABLE t1;
+# BUG#26624 high mem usage (crash) in range optimizer (depends on order of fields in where)
+create table t1 (
+ c1 char(10), c2 char(10), c3 char(10), c4 char(10),
+ c5 char(10), c6 char(10), c7 char(10), c8 char(10),
+ c9 char(10), c10 char(10), c11 char(10), c12 char(10),
+ c13 char(10), c14 char(10), c15 char(10), c16 char(10),
+ index(c1, c2, c3, c4, c5, c6, c7, c8, c9, c10, c11, c12,c13,c14,c15,c16)
+);
+
+insert into t1 (c1) values ('1'),('1'),('1'),('1');
+
+# This must run without crash and fast:
+select * from t1 where
+ c1 in ("abcdefgh", "123456789", "qwertyuio", "asddfgh")
+ and c2 in ("abcdefgh", "123456789", "qwertyuio", "asddfgh")
+ and c3 in ("abcdefgh", "123456789", "qwertyuio", "asddfgh")
+ and c4 in ("abcdefgh", "123456789", "qwertyuio", "asddfgh")
+ and c5 in ("abcdefgh", "123456789", "qwertyuio", "asddfgh")
+ and c6 in ("abcdefgh", "123456789", "qwertyuio", "asddfgh")
+ and c7 in ("abcdefgh", "123456789", "qwertyuio", "asddfgh")
+ and c8 in ("abcdefgh", "123456789", "qwertyuio", "asddfgh")
+ and c9 in ("abcdefgh", "123456789", "qwertyuio", "asddfgh")
+ and c10 in ("abcdefgh", "123456789", "qwertyuio", "asddfgh")
+ and c11 in ("abcdefgh", "123456789", "qwertyuio", "asddfgh")
+ and c12 in ("abcdefgh", "123456789", "qwertyuio", "asddfgh")
+ and c13 in ("abcdefgh", "123456789", "qwertyuio", "asddfgh")
+ and c14 in ("abcdefgh", "123456789", "qwertyuio", "asddfgh")
+ and c15 in ("abcdefgh", "123456789", "qwertyuio", "asddfgh")
+ and c16 in ("abcdefgh", "123456789", "qwertyuio", "asddfgh")
+;
+drop table t1;
+
--echo End of 4.1 tests
#