1
0
mirror of https://github.com/MariaDB/server.git synced 2026-01-06 05:22:24 +03:00

Bug #6019 SELECT tries to use too short prefix index on utf8 data

This commit is contained in:
unknown
2004-10-14 16:36:29 +05:00
parent a5484c0c6f
commit ae0acc8472
4 changed files with 32 additions and 2 deletions

View File

@@ -779,3 +779,14 @@ id term
2 testetest
3 test<73>test
DROP TABLE t1;
set names utf8;
create table t1 (
a int primary key,
b varchar(6),
index b3(b(3))
) engine=myisam character set=utf8;
insert into t1 values(1,'foo'),(2,'foobar');
select * from t1 where b like 'foob%';
a b
2 foobar
drop table t1;

View File

@@ -620,3 +620,18 @@ SELECT id, term FROM t1 where (list_id = 1) AND (term = "test
SELECT id, term FROM t1 where (list_id = 1) AND (term = "testetest");
SELECT id, term FROM t1 where (list_id = 1) AND (term = "test<73>test");
DROP TABLE t1;
#
# Bug #6019 SELECT tries to use too short prefix index on utf8 data
#
set names utf8;
--disable_warnings
create table t1 (
a int primary key,
b varchar(6),
index b3(b(3))
) engine=myisam character set=utf8;
--enable_warnings
insert into t1 values(1,'foo'),(2,'foobar');
select * from t1 where b like 'foob%';
drop table t1;