~linuxjedi/drizzle/trunk-bug-667053

« back to all changes in this revision

Viewing changes to mysql-test/t/ctype_cp1250_ch.test

  • Committer: brian
  • Date: 2008-06-25 05:29:13 UTC
  • Revision ID: brian@localhost.localdomain-20080625052913-6upwo0jsrl4lnapl
clean slate

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
-- source include/have_cp1250_ch.inc
 
2
--disable_warnings
 
3
drop table if exists t1;
 
4
--enable_warnings
 
5
 
 
6
--disable_warnings
 
7
DROP TABLE IF EXISTS t1;
 
8
--enable_warnings
 
9
 
 
10
SHOW COLLATION LIKE 'cp1250_czech_cs';
 
11
 
 
12
SET @test_character_set= 'cp1250';
 
13
SET @test_collation= 'cp1250_general_ci';
 
14
-- source include/ctype_common.inc
 
15
 
 
16
SET @test_character_set= 'cp1250';
 
17
SET @test_collation= 'cp1250_czech_cs';
 
18
-- source include/ctype_common.inc
 
19
 
 
20
 
 
21
 
 
22
#
 
23
# Bugs: #8840: Empty string comparison and character set 'cp1250'
 
24
#
 
25
 
 
26
CREATE TABLE t1 (a char(16)) character set cp1250 collate cp1250_czech_cs;
 
27
INSERT INTO t1 VALUES ('');
 
28
SELECT a, length(a), a='', a=' ', a='  ' FROM t1;
 
29
DROP TABLE t1;
 
30
 
 
31
#
 
32
# Bug#9759 Empty result with 'LIKE' and cp1250_czech_cs
 
33
#
 
34
CREATE TABLE t1 (
 
35
  popisek varchar(30) collate cp1250_general_ci NOT NULL default '',
 
36
 PRIMARY KEY  (`popisek`)
 
37
);
 
38
INSERT INTO t1 VALUES ('2005-01-1');
 
39
SELECT * FROM t1 WHERE popisek = '2005-01-1';
 
40
SELECT * FROM t1 WHERE popisek LIKE '2005-01-1';
 
41
drop table t1;
 
42
 
 
43
#
 
44
# Bug#13347: empty result from query with like and cp1250 charset
 
45
#
 
46
set names cp1250;
 
47
CREATE TABLE t1
 
48
(
 
49
 id  INT AUTO_INCREMENT PRIMARY KEY,
 
50
 str VARCHAR(32)  CHARACTER SET cp1250 COLLATE cp1250_czech_cs NOT NULL default '',
 
51
 UNIQUE KEY (str)
 
52
);
 
53
                        
 
54
INSERT INTO t1 VALUES (NULL, 'a');
 
55
INSERT INTO t1 VALUES (NULL, 'aa');
 
56
INSERT INTO t1 VALUES (NULL, 'aaa');
 
57
INSERT INTO t1 VALUES (NULL, 'aaaa');
 
58
INSERT INTO t1 VALUES (NULL, 'aaaaa');
 
59
INSERT INTO t1 VALUES (NULL, 'aaaaaa');
 
60
INSERT INTO t1 VALUES (NULL, 'aaaaaaa');
 
61
select * from t1 where str like 'aa%';
 
62
drop table t1;
 
63
 
 
64
#
 
65
# Bug#19741 segfault with cp1250 charset + like + primary key + 64bit os
 
66
#
 
67
set names cp1250;
 
68
create table t1 (a varchar(15) collate cp1250_czech_cs NOT NULL, primary key(a));
 
69
insert into t1 values("abcdefgh�");
 
70
insert into t1 values("����");
 
71
select a from t1 where a like "abcdefgh�";
 
72
drop table t1;
 
73
 
 
74
# End of 4.1 tests
 
75
 
 
76
 
 
77
set names cp1250 collate cp1250_czech_cs;
 
78
--source include/ctype_pad_space.inc
 
79
--source include/ctype_filesort.inc
 
80
--source include/weight_string.inc
 
81
--source include/weight_string_chde.inc
 
82
--source include/weight_string_l1.inc
 
83
--source include/weight_string_l2.inc
 
84
--source include/weight_string_l12.inc