diff options
author | monty@mysql.com <> | 2004-03-25 15:05:01 +0200 |
---|---|---|
committer | monty@mysql.com <> | 2004-03-25 15:05:01 +0200 |
commit | ebc3b3afac575b2c2a3e89823dfba217436a85c4 (patch) | |
tree | 27e5290a14e7d3e6c7aaced5b2ce86546de4721e /mysql-test/t/heap_btree.test | |
parent | 042af556d57f305734e64c7aa047e4709288f5bd (diff) | |
download | mariadb-git-ebc3b3afac575b2c2a3e89823dfba217436a85c4.tar.gz |
BTREE-indexes in HEAP tables can now be used to optimize ORDER BY
Don't read character set files if we are using only the default charset. In most cases the user will not anymore get a warning about missing character set files
Compare strings with space extend instead of space strip. Now the following comparisons holds: "a" == "a " and "a\t" < "a". (Bug #3152).
Note: Because of the above fix, one has to do a REPAIR on any table that has an ascii character < 32 last in a CHAR/VARCHAR/TEXT columns.
Diffstat (limited to 'mysql-test/t/heap_btree.test')
-rw-r--r-- | mysql-test/t/heap_btree.test | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/mysql-test/t/heap_btree.test b/mysql-test/t/heap_btree.test index a520065a8b3..ad78636d002 100644 --- a/mysql-test/t/heap_btree.test +++ b/mysql-test/t/heap_btree.test @@ -110,7 +110,13 @@ drop table t1; create table t1 (btn char(10) not null, key using BTREE (btn)) engine=heap; insert into t1 values ("hello"),("hello"),("hello"),("hello"),("hello"),("a"),("b"),("c"),("d"),("e"),("f"),("g"),("h"),("i"); -explain select * from t1 where btn like "q%"; +explain select * from t1 where btn like "i%"; +explain select * from t1 where btn like "h%"; +explain select * from t1 where btn like "a%"; +explain select * from t1 where btn like "b%"; +# For the following the BTREE MAY notice that there is no possible matches +select * from t1 where btn like "ff%"; +select * from t1 where btn like " %"; select * from t1 where btn like "q%"; alter table t1 add column new_col char(1) not null, add key using BTREE (btn,new_col), drop key btn; update t1 set new_col=left(btn,1); |