summaryrefslogtreecommitdiff
path: root/mysql-test/r/merge.result
diff options
context:
space:
mode:
authorunknown <gkodinov/kgeorge@macbook.gmz>2006-10-16 18:09:58 +0300
committerunknown <gkodinov/kgeorge@macbook.gmz>2006-10-16 18:09:58 +0300
commitffc1facce894359d5339ca7513a5518c2d829f29 (patch)
treeddf7474cc07baef2f6c1c4ff063b7613f711b03b /mysql-test/r/merge.result
parent78bf02870c9a277ae785ab5705b4a5c0556b149e (diff)
downloadmariadb-git-ffc1facce894359d5339ca7513a5518c2d829f29.tar.gz
Bug #22367: Optimizer uses ref join type instead of eq_ref for simple join on
strings MySQL is setting the flag HA_END_SPACE_KEYS for all the keys that reference text or varchar columns with collation different than binary. This was done to handle correctly the situation where a lookup on such a key may return more than 1 row because of the presence of many rows that differ only by the amount of trailing space in the table's string column. Inserting such values however appears to violate the unique checks on INSERT/UPDATE. Thus that flag must not be set as it will prevent the optimizer from choosing a faster access method. This fix removes the setting of the HA_END_SPACE_KEYS flag. include/my_base.h: Bug #22367: Optimizer uses ref join type instead of eq_ref for simple join on strings - disabled HA_END_SPACE_KEY as it's no longer needed mysql-test/r/func_str.result: Bug #22367: Optimizer uses ref join type instead of eq_ref for simple join on strings - fixed explain in an existing case mysql-test/r/merge.result: Bug #22367: Optimizer uses ref join type instead of eq_ref for simple join on strings - fixed explain in an existing case mysql-test/r/select.result: Bug #22367: Optimizer uses ref join type instead of eq_ref for simple join on strings - test case mysql-test/r/subselect.result: Bug #22367: Optimizer uses ref join type instead of eq_ref for simple join on strings - fixed explain in an existing case mysql-test/t/select.test: Bug #22367: Optimizer uses ref join type instead of eq_ref for simple join on strings - test case
Diffstat (limited to 'mysql-test/r/merge.result')
-rw-r--r--mysql-test/r/merge.result2
1 files changed, 1 insertions, 1 deletions
diff --git a/mysql-test/r/merge.result b/mysql-test/r/merge.result
index b8fdd24be74..5196462e97e 100644
--- a/mysql-test/r/merge.result
+++ b/mysql-test/r/merge.result
@@ -626,7 +626,7 @@ id select_type table type possible_keys key key_len ref rows Extra
EXPLAIN SELECT * FROM t2 WHERE fileset_id = 2
AND file_code = '0000000115' LIMIT 1;
id select_type table type possible_keys key key_len ref rows Extra
-1 SIMPLE t2 ref PRIMARY,files PRIMARY 35 const,const 1 Using where
+1 SIMPLE t2 const PRIMARY,files PRIMARY 35 const,const 1
DROP TABLE t2, t1;
create table t1 (x int, y int, index xy(x, y));
create table t2 (x int, y int, index xy(x, y));