summaryrefslogtreecommitdiff
path: root/mysql-test/r/selectivity_innodb.result
diff options
context:
space:
mode:
authorIgor Babaev <igor@askmonty.org>2013-04-06 00:51:41 -0700
committerIgor Babaev <igor@askmonty.org>2013-04-06 00:51:41 -0700
commitb2d0a33ea04a5eb20124667ea277fe78eb981a90 (patch)
treefdfc0bb22f3eaf253a52e69327a2fea24945d4f7 /mysql-test/r/selectivity_innodb.result
parent1ae352afbe40a71f26cec2da0f08eefdef05f41f (diff)
downloadmariadb-git-b2d0a33ea04a5eb20124667ea277fe78eb981a90.tar.gz
Fixed bug mdev-4373:
Valgrind complained on usage of uninitialized memory.
Diffstat (limited to 'mysql-test/r/selectivity_innodb.result')
-rw-r--r--mysql-test/r/selectivity_innodb.result17
1 files changed, 17 insertions, 0 deletions
diff --git a/mysql-test/r/selectivity_innodb.result b/mysql-test/r/selectivity_innodb.result
index 57037574e5d..5f4ddf76383 100644
--- a/mysql-test/r/selectivity_innodb.result
+++ b/mysql-test/r/selectivity_innodb.result
@@ -858,6 +858,23 @@ set optimizer_switch=@save_optimizer_switch;
set optimizer_use_condition_selectivity=@save_optimizer_use_condition_selectivity;
DROP TABLE t1,t2;
set use_stat_tables=@save_use_stat_tables;
+#
+# Bug mdev-4373: condition on a short varchar column
+# with optimizer_use_condition_selectivity=3
+#
+set use_stat_tables=PREFERABLY;
+CREATE TABLE t1 (a varchar(1));
+INSERT INTO t1 VALUES ('x'), ('y');
+ANALYZE TABLE t1;
+Table Op Msg_type Msg_text
+test.t1 analyze status OK
+FLUSH TABLES;
+set optimizer_use_condition_selectivity=3;
+SELECT * FROM t1 WHERE a <= 'w';
+a
+set optimizer_use_condition_selectivity=@save_optimizer_use_condition_selectivity;
+DROP TABLE t1;
+set use_stat_tables=@save_use_stat_tables;
set use_stat_tables=@save_use_stat_tables;
set optimizer_switch=@save_optimizer_switch_for_selectivity_test;
SET SESSION STORAGE_ENGINE=DEFAULT;