1#
2# Bugs: #13046:
3# LIKE pattern matching using prefix index doesn't return correct result
4#
5select @@collation_connection;
6create table t1 ROW_FORMAT=DYNAMIC select repeat('a',50) as c1 ;
7insert into t1 values('abcdef');
8insert into t1 values('_bcdef');
9insert into t1 values('a_cdef');
10insert into t1 values('ab_def');
11insert into t1 values('abc_ef');
12insert into t1 values('abcd_f');
13insert into t1 values('abcde_');
14# should return ab_def
15select c1 as c1u from t1 where c1 like 'ab\_def';
16# should return ab_def
17select c1 as c2h from t1 where c1 like 'ab#_def' escape '#';
18drop table t1;
19
20#
21# MDEV-13335 UTF8 escape wildcard LIKE match has different behavior in different collations
22#
23SELECT @@collation_connection;
24SELECT '\%b' LIKE '%\%';
25