Commit 49d2b4f0 authored by unknown's avatar unknown
Browse files

Merge abarkov@bk-internal.mysql.com:/home/bk/mysql-4.1

into  mysql.com:/usr/home/bar/mysql-4.1.b17374

parents 7913527e 83bc8c4e
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -342,6 +342,11 @@ int my_wildcmp_8bit(CHARSET_INFO *,
		    const char *wildstr,const char *wildend,
		    int escape, int w_one, int w_many);

int my_wildcmp_bin(CHARSET_INFO *,
		   const char *str,const char *str_end,
		   const char *wildstr,const char *wildend,
		   int escape, int w_one, int w_many);

uint my_numchars_8bit(CHARSET_INFO *, const char *b, const char *e);
uint my_numcells_8bit(CHARSET_INFO *, const char *b, const char *e);
uint my_charpos_8bit(CHARSET_INFO *, const char *b, const char *e, uint pos);
+4 −0
Original line number Diff line number Diff line
-- require r/have_latin2_ch.require
disable_query_log;
show collation like "latin2_czech_cs";
enable_query_log;
+30 −0
Original line number Diff line number Diff line
drop table if exists t1;
set names latin2;
select 'A' = 'a' collate latin2_czech_cs;
'A' = 'a' collate latin2_czech_cs
0
create table t1 (
id  int(5) not null,    
tt  char(255) not null
) character set latin2 collate latin2_czech_cs;
insert into t1 values (1,'Aa');
insert into t1 values (2,'Aas');
alter table t1 add primary key aaa(tt);
select * from t1 where tt like 'Aa%';
id	tt
1	Aa
2	Aas
select * from t1 ignore index (primary) where tt like 'Aa%';
id	tt
1	Aa
2	Aas
select * from t1 where tt like '%Aa%';
id	tt
1	Aa
2	Aas
select * from t1 where tt like 'AA%';
id	tt
select * from t1 ignore index (primary) where tt like 'AA%';
id	tt
select * from t1 where tt like '%AA%';
id	tt
+2 −0
Original line number Diff line number Diff line
Collation	Charset	Id	Default	Compiled	Sortlen
latin2_czech_cs	latin2	2		Yes	4
+30 −0
Original line number Diff line number Diff line
-- source include/have_latin2_ch.inc

#
# Tests with latin2_czech_cs
#
--disable_warnings
drop table if exists t1;
--enable_warnings

#
# Bug#17374: select ... like 'A%' operator fails
# to find value on columuns with key
#
set names latin2;
select 'A' = 'a' collate latin2_czech_cs;
create table t1 (
    id  int(5) not null,    
    tt  char(255) not null
) character set latin2 collate latin2_czech_cs;
insert into t1 values (1,'Aa');
insert into t1 values (2,'Aas');
alter table t1 add primary key aaa(tt); 
select * from t1 where tt like 'Aa%';
select * from t1 ignore index (primary) where tt like 'Aa%';
select * from t1 where tt like '%Aa%';
select * from t1 where tt like 'AA%';
select * from t1 ignore index (primary) where tt like 'AA%';
select * from t1 where tt like '%AA%';

# End of 4.1 tests
Loading