~stewart/drizzle/embedded-innodb-create-select-transaction-arrgh

« back to all changes in this revision

Viewing changes to mysql-test/t/ctype_big5.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_big5.inc
 
2
 
 
3
#
 
4
# Tests with the big5 character set
 
5
#
 
6
--disable_warnings
 
7
drop table if exists t1;
 
8
--enable_warnings
 
9
 
 
10
SET @test_character_set= 'big5';
 
11
SET @test_collation= 'big5_chinese_ci';
 
12
-- source include/ctype_common.inc
 
13
 
 
14
SET NAMES big5;
 
15
SET collation_connection='big5_chinese_ci';
 
16
-- source include/ctype_filesort.inc
 
17
-- source include/ctype_innodb_like.inc
 
18
-- source include/ctype_like_escape.inc
 
19
-- source include/ctype_like_range_f1f2.inc
 
20
SET collation_connection='big5_bin';
 
21
-- source include/ctype_filesort.inc
 
22
-- source include/ctype_innodb_like.inc
 
23
-- source include/ctype_like_escape.inc
 
24
-- source include/ctype_like_range_f1f2.inc
 
25
 
 
26
#
 
27
# Bugs#9357: TEXT columns break string with special word in BIG5 charset.
 
28
#
 
29
SET NAMES big5;
 
30
CREATE TABLE t1 (a text) character set big5;
 
31
INSERT INTO t1 VALUES ('��');
 
32
SELECT * FROM t1;
 
33
DROP TABLE t1;
 
34
 
 
35
#
 
36
# BUG#12075 - FULLTEXT non-functional for big5 strings
 
37
#
 
38
CREATE TABLE t1 (a CHAR(50) CHARACTER SET big5 NOT NULL, FULLTEXT(a));
 
39
INSERT INTO t1 VALUES(0xA741ADCCA66EB6DC20A7DAADCCABDCA66E);
 
40
SELECT HEX(a) FROM t1 WHERE MATCH(a) AGAINST (0xA741ADCCA66EB6DC IN BOOLEAN MODE);
 
41
DROP TABLE t1;
 
42
 
 
43
#
 
44
# Bug#12476 Some big5 codes are still missing.
 
45
#
 
46
set names big5;
 
47
create table t1 (a char character set big5);
 
48
insert into t1 values (0xF9D6),(0xF9D7),(0xF9D8),(0xF9D9);
 
49
insert into t1 values (0xF9DA),(0xF9DB),(0xF9DC);
 
50
# Check round trip
 
51
select hex(a) a, hex(@u:=convert(a using utf8)) b,
 
52
hex(convert(@u using big5)) c from t1 order by a;
 
53
# Check that there is no "illegal mix of collations" error with Unicode.
 
54
alter table t1 convert to character set utf8;
 
55
select hex(a) from t1 where a = _big5 0xF9DC;
 
56
drop table t1;
 
57
 
 
58
#
 
59
# Bugs#15375: Unassigned multibyte codes are broken
 
60
# into parts when converting to Unicode.
 
61
# This query should return 0x003F0041. I.e. it should
 
62
# scan unassigned double-byte character 0xC840, convert
 
63
# it as QUESTION MARK 0x003F and then scan the next
 
64
# character, which is a single byte character 0x41.
 
65
#
 
66
select hex(convert(_big5 0xC84041 using ucs2));
 
67
 
 
68
--echo End of 4.1 tests
 
69
 
 
70
#
 
71
# Bug#26711 "binary content 0x00 sometimes becomes 0x5C 0x00 after dump/load"
 
72
#
 
73
set names big5;
 
74
create table t1 (a blob);
 
75
insert into t1 values (0xEE00);
 
76
select * into outfile 'test/t1.txt' from t1;
 
77
delete from t1;
 
78
--replace_result $MYSQLTEST_VARDIR MYSQLTEST_VARDIR
 
79
--eval select hex(load_file('$MYSQLTEST_VARDIR/master-data/test/t1.txt'));
 
80
load data infile 't1.txt' into table t1;
 
81
select hex(a) from t1;
 
82
--exec rm $MYSQLTEST_VARDIR/master-data/test/t1.txt
 
83
drop table t1;
 
84
 
 
85
--echo End of 5.0 tests
 
86
 
 
87
 
 
88
set names big5;
 
89
--source include/weight_string.inc
 
90
--source include/weight_string_l1.inc
 
91
--source include/weight_string_A1A1.inc
 
92
 
 
93
set collation_connection=big5_bin;
 
94
--source include/weight_string.inc
 
95
--source include/weight_string_l1.inc
 
96
--source include/weight_string_A1A1.inc