1
by brian
clean slate |
1 |
--source include/have_ujis.inc
|
2 |
||
3 |
--disable_warnings
|
|
4 |
drop table if exists `£Ô£±`; |
|
5 |
drop table if exists `£Ô£²`; |
|
6 |
drop table if exists `£Ô£³`; |
|
7 |
drop table if exists `£Ô£Ž`; |
|
8 |
drop table if exists `£Ô£µ`; |
|
9 |
drop table if exists `£Ô£¶`; |
|
10 |
drop table if exists `£Ô£·`; |
|
11 |
drop table if exists `£Ô£ž`; |
|
12 |
drop table if exists `£Ô£¹`; |
|
13 |
drop table if exists `£Ô£±£°`; |
|
14 |
--enable_warnings
|
|
15 |
||
16 |
#
|
|
17 |
# Test TRIM() function with Japanese characters ujis encoding |
|
18 |
#
|
|
19 |
||
20 |
SET NAMES ujis; |
|
21 |
SET character_set_database = ujis; |
|
22 |
||
23 |
CREATE TABLE `£Ô£±` (`£Ã£±` char(12), INDEX(`£Ã£±`)) DEFAULT CHARSET = ujis engine = innodb; |
|
24 |
CREATE TABLE `£Ô£²` (`£Ã£±` char(12), INDEX(`£Ã£±`)) DEFAULT CHARSET = ujis engine = innodb; |
|
25 |
CREATE TABLE `£Ô£³` (`£Ã£±` char(12), INDEX(`£Ã£±`)) DEFAULT CHARSET = ujis engine = innodb; |
|
26 |
CREATE TABLE `£Ô£Ž` (`£Ã£±` char(12), INDEX(`£Ã£±`)) DEFAULT CHARSET = ujis engine = myisam; |
|
27 |
CREATE TABLE `£Ô£µ` (`£Ã£±` char(12), INDEX(`£Ã£±`)) DEFAULT CHARSET = ujis engine = myisam; |
|
28 |
CREATE TABLE `£Ô£¶` (`£Ã£±` char(12), INDEX(`£Ã£±`)) DEFAULT CHARSET = ujis engine = myisam; |
|
29 |
CREATE TABLE `£Ô£·` (`£Ã£±` char(12), INDEX(`£Ã£±`)) DEFAULT CHARSET = ujis engine = heap; |
|
30 |
CREATE TABLE `£Ô£ž` (`£Ã£±` char(12), INDEX(`£Ã£±`)) DEFAULT CHARSET = ujis engine = heap; |
|
31 |
CREATE TABLE `£Ô£¹` (`£Ã£±` char(12), INDEX(`£Ã£±`)) DEFAULT CHARSET = ujis engine = heap; |
|
32 |
CREATE TABLE `£Ô£±£°` (`£Ã£±` char(12), INDEX(`£Ã£±`)) DEFAULT CHARSET = ujis engine = bdb; |
|
33 |
CREATE TABLE `£Ô£±£±` (`£Ã£±` char(12), INDEX(`£Ã£±`)) DEFAULT CHARSET = ujis engine = bdb; |
|
34 |
CREATE TABLE `£Ô£±£²` (`£Ã£±` char(12), INDEX(`£Ã£±`)) DEFAULT CHARSET = ujis engine = bdb; |
|
35 |
||
36 |
# Nothing to trim |
|
37 |
INSERT INTO `£Ô£±` VALUES ('±²³Žµ'); |
|
38 |
# Test data for TRIM(TRAILING [remstr] FROM str) |
|
39 |
INSERT INTO `£Ô£±` VALUES ('±²³Žµ¶'); |
|
40 |
INSERT INTO `£Ô£±` VALUES ('±²³Žµ¶¶'); |
|
41 |
INSERT INTO `£Ô£±` VALUES ('±²³Žµ¶¶¶'); |
|
42 |
# Test data for TRIM(LEADING [remstr] FROM str) |
|
43 |
INSERT INTO `£Ô£±` VALUES ('¶±²³Žµ'); |
|
44 |
INSERT INTO `£Ô£±` VALUES ('¶¶±²³Žµ'); |
|
45 |
INSERT INTO `£Ô£±` VALUES ('¶¶¶±²³Žµ'); |
|
46 |
# Test data for TRIM(BOTH [remstr] FROM str) |
|
47 |
INSERT INTO `£Ô£±` VALUES ('¶¶¶±²³Žµ¶¶¶'); |
|
48 |
# Test data for TRIM without [remstr] (remove spaces) |
|
49 |
INSERT INTO `£Ô£±` VALUES (' ±²³Žµ '); |
|
50 |
INSERT INTO `£Ô£²` VALUES ('€¢€€€Š€š€ª'); |
|
51 |
INSERT INTO `£Ô£²` VALUES ('€¢€€€Š€š€ª€«'); |
|
52 |
INSERT INTO `£Ô£²` VALUES ('€¢€€€Š€š€ª€«€«'); |
|
53 |
INSERT INTO `£Ô£²` VALUES ('€¢€€€Š€š€ª€«€«€«'); |
|
54 |
INSERT INTO `£Ô£²` VALUES ('€«€¢€€€Š€š€ª'); |
|
55 |
INSERT INTO `£Ô£²` VALUES ('€«€«€¢€€€Š€š€ª'); |
|
56 |
INSERT INTO `£Ô£²` VALUES ('€«€«€«€¢€€€Š€š€ª'); |
|
57 |
INSERT INTO `£Ô£²` VALUES ('€«€«€«€¢€€€Š€š€ª€«€«€«'); |
|
58 |
INSERT INTO `£Ô£²` VALUES (' €¢€€€Š€š€ª '); |
|
59 |
INSERT INTO `£Ô£³` VALUES ('íÜíÝíÞíßíà'); |
|
60 |
INSERT INTO `£Ô£³` VALUES ('íÜíÝíÞíßíà°¡'); |
|
61 |
INSERT INTO `£Ô£³` VALUES ('íÜíÝíÞíßíà°¡°¡'); |
|
62 |
INSERT INTO `£Ô£³` VALUES ('íÜíÝíÞíßíà°¡°¡°¡'); |
|
63 |
INSERT INTO `£Ô£³` VALUES ('°¡íÜíÝíÞíßíà'); |
|
64 |
INSERT INTO `£Ô£³` VALUES ('°¡°¡íÜíÝíÞíßíà'); |
|
65 |
INSERT INTO `£Ô£³` VALUES ('°¡°¡°¡íÜíÝíÞíßíà'); |
|
66 |
INSERT INTO `£Ô£³` VALUES ('°¡°¡°¡íÜíÝíÞíßíà°¡°¡°¡'); |
|
67 |
INSERT INTO `£Ô£³` VALUES (' íÜíÝíÞíßíà '); |
|
68 |
||
69 |
INSERT INTO `£Ô£Ž` VALUES ('±²³Žµ'); |
|
70 |
INSERT INTO `£Ô£Ž` VALUES ('±²³Žµ¶'); |
|
71 |
INSERT INTO `£Ô£Ž` VALUES ('±²³Žµ¶¶'); |
|
72 |
INSERT INTO `£Ô£Ž` VALUES ('±²³Žµ¶¶¶'); |
|
73 |
INSERT INTO `£Ô£Ž` VALUES ('¶±²³Žµ'); |
|
74 |
INSERT INTO `£Ô£Ž` VALUES ('¶¶±²³Žµ'); |
|
75 |
INSERT INTO `£Ô£Ž` VALUES ('¶¶¶±²³Žµ'); |
|
76 |
INSERT INTO `£Ô£Ž` VALUES ('¶¶¶±²³Žµ¶¶¶'); |
|
77 |
INSERT INTO `£Ô£Ž` VALUES (' ±²³Žµ '); |
|
78 |
INSERT INTO `£Ô£µ` VALUES ('€¢€€€Š€š€ª'); |
|
79 |
INSERT INTO `£Ô£µ` VALUES ('€¢€€€Š€š€ª€«'); |
|
80 |
INSERT INTO `£Ô£µ` VALUES ('€¢€€€Š€š€ª€«€«'); |
|
81 |
INSERT INTO `£Ô£µ` VALUES ('€¢€€€Š€š€ª€«€«€«'); |
|
82 |
INSERT INTO `£Ô£µ` VALUES ('€«€¢€€€Š€š€ª'); |
|
83 |
INSERT INTO `£Ô£µ` VALUES ('€«€«€¢€€€Š€š€ª'); |
|
84 |
INSERT INTO `£Ô£µ` VALUES ('€«€«€«€¢€€€Š€š€ª'); |
|
85 |
INSERT INTO `£Ô£µ` VALUES ('€«€«€«€¢€€€Š€š€ª€«€«€«'); |
|
86 |
INSERT INTO `£Ô£µ` VALUES (' €¢€€€Š€š€ª '); |
|
87 |
INSERT INTO `£Ô£¶` VALUES ('íÜíÝíÞíßíà'); |
|
88 |
INSERT INTO `£Ô£¶` VALUES ('íÜíÝíÞíßíà°¡'); |
|
89 |
INSERT INTO `£Ô£¶` VALUES ('íÜíÝíÞíßíà°¡°¡'); |
|
90 |
INSERT INTO `£Ô£¶` VALUES ('íÜíÝíÞíßíà°¡°¡°¡'); |
|
91 |
INSERT INTO `£Ô£¶` VALUES ('°¡íÜíÝíÞíßíà'); |
|
92 |
INSERT INTO `£Ô£¶` VALUES ('°¡°¡íÜíÝíÞíßíà'); |
|
93 |
INSERT INTO `£Ô£¶` VALUES ('°¡°¡°¡íÜíÝíÞíßíà'); |
|
94 |
INSERT INTO `£Ô£¶` VALUES ('°¡°¡°¡íÜíÝíÞíßíà°¡°¡°¡'); |
|
95 |
INSERT INTO `£Ô£¶` VALUES (' íÜíÝíÞíßíà '); |
|
96 |
||
97 |
INSERT INTO `£Ô£·` VALUES ('±²³Žµ'); |
|
98 |
INSERT INTO `£Ô£·` VALUES ('±²³Žµ¶'); |
|
99 |
INSERT INTO `£Ô£·` VALUES ('±²³Žµ¶¶'); |
|
100 |
INSERT INTO `£Ô£·` VALUES ('±²³Žµ¶¶¶'); |
|
101 |
INSERT INTO `£Ô£·` VALUES ('¶±²³Žµ'); |
|
102 |
INSERT INTO `£Ô£·` VALUES ('¶¶±²³Žµ'); |
|
103 |
INSERT INTO `£Ô£·` VALUES ('¶¶¶±²³Žµ'); |
|
104 |
INSERT INTO `£Ô£·` VALUES ('¶¶¶±²³Žµ¶¶¶'); |
|
105 |
INSERT INTO `£Ô£·` VALUES (' ±²³Žµ '); |
|
106 |
INSERT INTO `£Ô£ž` VALUES ('€¢€€€Š€š€ª'); |
|
107 |
INSERT INTO `£Ô£ž` VALUES ('€¢€€€Š€š€ª€«'); |
|
108 |
INSERT INTO `£Ô£ž` VALUES ('€¢€€€Š€š€ª€«€«'); |
|
109 |
INSERT INTO `£Ô£ž` VALUES ('€¢€€€Š€š€ª€«€«€«'); |
|
110 |
INSERT INTO `£Ô£ž` VALUES ('€«€¢€€€Š€š€ª'); |
|
111 |
INSERT INTO `£Ô£ž` VALUES ('€«€«€¢€€€Š€š€ª'); |
|
112 |
INSERT INTO `£Ô£ž` VALUES ('€«€«€«€¢€€€Š€š€ª'); |
|
113 |
INSERT INTO `£Ô£ž` VALUES ('€«€«€«€¢€€€Š€š€ª€«€«€«'); |
|
114 |
INSERT INTO `£Ô£ž` VALUES (' €¢€€€Š€š€ª '); |
|
115 |
INSERT INTO `£Ô£¹` VALUES ('íÜíÝíÞíßíà'); |
|
116 |
INSERT INTO `£Ô£¹` VALUES ('íÜíÝíÞíßíà°¡'); |
|
117 |
INSERT INTO `£Ô£¹` VALUES ('íÜíÝíÞíßíà°¡°¡'); |
|
118 |
INSERT INTO `£Ô£¹` VALUES ('íÜíÝíÞíßíà°¡°¡°¡'); |
|
119 |
INSERT INTO `£Ô£¹` VALUES ('°¡íÜíÝíÞíßíà'); |
|
120 |
INSERT INTO `£Ô£¹` VALUES ('°¡°¡íÜíÝíÞíßíà'); |
|
121 |
INSERT INTO `£Ô£¹` VALUES ('°¡°¡°¡íÜíÝíÞíßíà'); |
|
122 |
INSERT INTO `£Ô£¹` VALUES ('°¡°¡°¡íÜíÝíÞíßíà°¡°¡°¡'); |
|
123 |
INSERT INTO `£Ô£¹` VALUES (' íÜíÝíÞíßíà '); |
|
124 |
||
125 |
INSERT INTO `£Ô£±£°` VALUES ('±²³Žµ'); |
|
126 |
INSERT INTO `£Ô£±£°` VALUES ('±²³Žµ¶'); |
|
127 |
INSERT INTO `£Ô£±£°` VALUES ('±²³Žµ¶¶'); |
|
128 |
INSERT INTO `£Ô£±£°` VALUES ('±²³Žµ¶¶¶'); |
|
129 |
INSERT INTO `£Ô£±£°` VALUES ('¶±²³Žµ'); |
|
130 |
INSERT INTO `£Ô£±£°` VALUES ('¶¶±²³Žµ'); |
|
131 |
INSERT INTO `£Ô£±£°` VALUES ('¶¶¶±²³Žµ'); |
|
132 |
INSERT INTO `£Ô£±£°` VALUES ('¶¶¶±²³Žµ¶¶¶'); |
|
133 |
INSERT INTO `£Ô£±£°` VALUES (' ±²³Žµ '); |
|
134 |
INSERT INTO `£Ô£±£±` VALUES ('€¢€€€Š€š€ª'); |
|
135 |
INSERT INTO `£Ô£±£±` VALUES ('€¢€€€Š€š€ª€«'); |
|
136 |
INSERT INTO `£Ô£±£±` VALUES ('€¢€€€Š€š€ª€«€«'); |
|
137 |
INSERT INTO `£Ô£±£±` VALUES ('€¢€€€Š€š€ª€«€«€«'); |
|
138 |
INSERT INTO `£Ô£±£±` VALUES ('€«€¢€€€Š€š€ª'); |
|
139 |
INSERT INTO `£Ô£±£±` VALUES ('€«€«€¢€€€Š€š€ª'); |
|
140 |
INSERT INTO `£Ô£±£±` VALUES ('€«€«€«€¢€€€Š€š€ª'); |
|
141 |
INSERT INTO `£Ô£±£±` VALUES ('€«€«€«€¢€€€Š€š€ª€«€«€«'); |
|
142 |
INSERT INTO `£Ô£±£±` VALUES (' €¢€€€Š€š€ª '); |
|
143 |
INSERT INTO `£Ô£±£²` VALUES ('íÜíÝíÞíßíà'); |
|
144 |
INSERT INTO `£Ô£±£²` VALUES ('íÜíÝíÞíßíà°¡'); |
|
145 |
INSERT INTO `£Ô£±£²` VALUES ('íÜíÝíÞíßíà°¡°¡'); |
|
146 |
INSERT INTO `£Ô£±£²` VALUES ('íÜíÝíÞíßíà°¡°¡°¡'); |
|
147 |
INSERT INTO `£Ô£±£²` VALUES ('°¡íÜíÝíÞíßíà'); |
|
148 |
INSERT INTO `£Ô£±£²` VALUES ('°¡°¡íÜíÝíÞíßíà'); |
|
149 |
INSERT INTO `£Ô£±£²` VALUES ('°¡°¡°¡íÜíÝíÞíßíà'); |
|
150 |
INSERT INTO `£Ô£±£²` VALUES ('°¡°¡°¡íÜíÝíÞíßíà°¡°¡°¡'); |
|
151 |
INSERT INTO `£Ô£±£²` VALUES (' íÜíÝíÞíßíà '); |
|
152 |
||
153 |
#InnoDB |
|
154 |
SELECT `£Ã£±`,TRIM(TRAILING '¶' FROM `£Ã£±`) FROM `£Ô£±`; |
|
155 |
SELECT `£Ã£±`,TRIM(LEADING '¶' FROM `£Ã£±`) FROM `£Ô£±`; |
|
156 |
SELECT `£Ã£±`,TRIM(BOTH '¶' FROM `£Ã£±`) FROM `£Ô£±`; |
|
157 |
SELECT `£Ã£±`,TRIM(`£Ã£±`) FROM `£Ô£±`; |
|
158 |
SELECT `£Ã£±`,TRIM(TRAILING '€«' FROM `£Ã£±`) FROM `£Ô£²`; |
|
159 |
SELECT `£Ã£±`,TRIM(LEADING '€«' FROM `£Ã£±`) FROM `£Ô£²`; |
|
160 |
SELECT `£Ã£±`,TRIM(BOTH '€«' FROM `£Ã£±`) FROM `£Ô£²`; |
|
161 |
SELECT `£Ã£±`,TRIM(`£Ã£±`) FROM `£Ô£²`; |
|
162 |
SELECT `£Ã£±`,TRIM(TRAILING '°¡'FROM `£Ã£±`) FROM `£Ô£³`; |
|
163 |
SELECT `£Ã£±`,TRIM(LEADING '°¡' FROM `£Ã£±`) FROM `£Ô£³`; |
|
164 |
SELECT `£Ã£±`,TRIM(BOTH '°¡' FROM `£Ã£±`) FROM `£Ô£³`; |
|
165 |
SELECT `£Ã£±`,TRIM(`£Ã£±`) FROM `£Ô£³`; |
|
166 |
||
167 |
#MyISAM |
|
168 |
SELECT `£Ã£±`,TRIM(TRAILING '¶' FROM `£Ã£±`) FROM `£Ô£Ž`; |
|
169 |
SELECT `£Ã£±`,TRIM(LEADING '¶' FROM `£Ã£±`) FROM `£Ô£Ž`; |
|
170 |
SELECT `£Ã£±`,TRIM(BOTH '¶' FROM `£Ã£±`) FROM `£Ô£Ž`; |
|
171 |
SELECT `£Ã£±`,TRIM(`£Ã£±`) FROM `£Ô£Ž`; |
|
172 |
SELECT `£Ã£±`,TRIM(TRAILING '€«' FROM `£Ã£±`) FROM `£Ô£µ`; |
|
173 |
SELECT `£Ã£±`,TRIM(LEADING '€«' FROM `£Ã£±`) FROM `£Ô£µ`; |
|
174 |
SELECT `£Ã£±`,TRIM(BOTH '€«' FROM `£Ã£±`) FROM `£Ô£µ`; |
|
175 |
SELECT `£Ã£±`,TRIM(`£Ã£±`) FROM `£Ô£µ`; |
|
176 |
SELECT `£Ã£±`,TRIM(TRAILING '°¡' FROM `£Ã£±`) FROM `£Ô£¶`; |
|
177 |
SELECT `£Ã£±`,TRIM(LEADING '°¡' FROM `£Ã£±`) FROM `£Ô£¶`; |
|
178 |
SELECT `£Ã£±`,TRIM(BOTH '°¡' FROM `£Ã£±`) FROM `£Ô£¶`; |
|
179 |
SELECT `£Ã£±`,TRIM(`£Ã£±`) FROM `£Ô£¶`; |
|
180 |
||
181 |
#HEAP |
|
182 |
SELECT `£Ã£±`,TRIM(TRAILING '¶' FROM `£Ã£±`) FROM `£Ô£·`; |
|
183 |
SELECT `£Ã£±`,TRIM(LEADING '¶' FROM `£Ã£±`) FROM `£Ô£·`; |
|
184 |
SELECT `£Ã£±`,TRIM(BOTH '¶' FROM `£Ã£±`) FROM `£Ô£·`; |
|
185 |
SELECT `£Ã£±`,TRIM(`£Ã£±`) FROM `£Ô£·`; |
|
186 |
SELECT `£Ã£±`,TRIM(TRAILING '€«' FROM `£Ã£±`) FROM `£Ô£ž`; |
|
187 |
SELECT `£Ã£±`,TRIM(LEADING '€«' FROM `£Ã£±`) FROM `£Ô£ž`; |
|
188 |
SELECT `£Ã£±`,TRIM(BOTH '€«' FROM `£Ã£±`) FROM `£Ô£ž`; |
|
189 |
SELECT `£Ã£±`,TRIM(`£Ã£±`) FROM `£Ô£ž`; |
|
190 |
SELECT `£Ã£±`,TRIM(TRAILING '°¡' FROM `£Ã£±`) FROM `£Ô£¹`; |
|
191 |
SELECT `£Ã£±`,TRIM(LEADING '°¡' FROM `£Ã£±`) FROM `£Ô£¹`; |
|
192 |
SELECT `£Ã£±`,TRIM(BOTH '°¡' FROM `£Ã£±`) FROM `£Ô£¹`; |
|
193 |
SELECT `£Ã£±`,TRIM(`£Ã£±`) FROM `£Ô£¹`; |
|
194 |
||
195 |
#BDB |
|
196 |
SELECT `£Ã£±`,TRIM(TRAILING '¶' FROM `£Ã£±`) FROM `£Ô£±£°`; |
|
197 |
SELECT `£Ã£±`,TRIM(LEADING '¶' FROM `£Ã£±`) FROM `£Ô£±£°`; |
|
198 |
SELECT `£Ã£±`,TRIM(BOTH '¶' FROM `£Ã£±`) FROM `£Ô£±£°`; |
|
199 |
SELECT `£Ã£±`,TRIM(`£Ã£±`) FROM `£Ô£±£°`; |
|
200 |
SELECT `£Ã£±`,TRIM(TRAILING '€«' FROM `£Ã£±`) FROM `£Ô£±£±`; |
|
201 |
SELECT `£Ã£±`,TRIM(LEADING '€«' FROM `£Ã£±`) FROM `£Ô£±£±`; |
|
202 |
SELECT `£Ã£±`,TRIM(BOTH '€«' FROM `£Ã£±`) FROM `£Ô£±£±`; |
|
203 |
SELECT `£Ã£±`,TRIM(`£Ã£±`) FROM `£Ô£±£±`; |
|
204 |
SELECT `£Ã£±`,TRIM(TRAILING '°¡' FROM `£Ã£±`) FROM `£Ô£±£²`; |
|
205 |
SELECT `£Ã£±`,TRIM(LEADING '°¡' FROM `£Ã£±`) FROM `£Ô£±£²`; |
|
206 |
SELECT `£Ã£±`,TRIM(BOTH '°¡' FROM `£Ã£±`) FROM `£Ô£±£²`; |
|
207 |
SELECT `£Ã£±`,TRIM(`£Ã£±`) FROM `£Ô£±£²`; |
|
208 |
||
209 |
DROP TABLE `£Ô£±`; |
|
210 |
DROP TABLE `£Ô£²`; |
|
211 |
DROP TABLE `£Ô£³`; |
|
212 |
DROP TABLE `£Ô£Ž`; |
|
213 |
DROP TABLE `£Ô£µ`; |
|
214 |
DROP TABLE `£Ô£¶`; |
|
215 |
DROP TABLE `£Ô£·`; |
|
216 |
DROP TABLE `£Ô£ž`; |
|
217 |
DROP TABLE `£Ô£¹`; |
|
218 |
DROP TABLE `£Ô£±£°`; |
|
219 |
DROP TABLE `£Ô£±£±`; |
|
220 |
DROP TABLE `£Ô£±£²`; |