mirror of
https://github.com/MariaDB/server.git
synced 2025-07-30 16:24:05 +03:00
Optimize LIKE with turbo-boyer-more algoritm
This commit is contained in:
@ -15,4 +15,15 @@ test
|
||||
select * from t1 where a like "te_t";
|
||||
a
|
||||
test
|
||||
select * from t1 where a like "%a%";
|
||||
a
|
||||
a
|
||||
abc
|
||||
abcd
|
||||
select * from t1 where a like "%abcd%";
|
||||
a
|
||||
abcd
|
||||
select * from t1 where a like "%abc\d%";
|
||||
a
|
||||
abcd
|
||||
drop table t1;
|
||||
|
@ -9,4 +9,12 @@ select * from t1 where a like "abc%";
|
||||
select * from t1 where a like "ABC%";
|
||||
select * from t1 where a like "test%";
|
||||
select * from t1 where a like "te_t";
|
||||
|
||||
#
|
||||
# The following will test the boyer-more code
|
||||
#
|
||||
select * from t1 where a like "%a%";
|
||||
select * from t1 where a like "%abcd%";
|
||||
select * from t1 where a like "%abc\d%";
|
||||
|
||||
drop table t1;
|
||||
|
Reference in New Issue
Block a user