diff options
author | Alexander Barkov <bar@mnogosearch.org> | 2013-10-23 20:25:52 +0400 |
---|---|---|
committer | Alexander Barkov <bar@mnogosearch.org> | 2013-10-23 20:25:52 +0400 |
commit | 426d246f5b8a4c598a913838b625e05e63ccb41f (patch) | |
tree | 16792dd3268c0ec0fb02837c761a535af1938b1f /mysql-test/r/ctype_utf16_uca.result | |
parent | de8e306b6921ab32aedde957594e570166a7fce1 (diff) | |
download | mariadb-git-426d246f5b8a4c598a913838b625e05e63ccb41f.tar.gz |
MDEV-5163 Merge WEIGHT_STRING function from MySQL-5.6
Diffstat (limited to 'mysql-test/r/ctype_utf16_uca.result')
-rw-r--r-- | mysql-test/r/ctype_utf16_uca.result | 401 |
1 files changed, 401 insertions, 0 deletions
diff --git a/mysql-test/r/ctype_utf16_uca.result b/mysql-test/r/ctype_utf16_uca.result index fe715ba1438..c33b27d5317 100644 --- a/mysql-test/r/ctype_utf16_uca.result +++ b/mysql-test/r/ctype_utf16_uca.result @@ -2290,6 +2290,66 @@ select c1 as c2h from t1 where c1 like 'ab#_def' escape '#'; c2h ab_def drop table t1; +drop table if exists t1; +create table t1 as select repeat(' ', 64) as s1; +select collation(s1) from t1; +collation(s1) +utf16_unicode_ci +delete from t1; +insert into t1 values ('a'),('ae'),(_latin1 0xE4); +insert into t1 values ('o'),('oe'),(_latin1 0xF6); +insert into t1 values ('s'),('ss'),(_latin1 0xDF); +insert into t1 values ('u'),('ue'),(_latin1 0xFC); +select s1, hex(s1) from t1 order by s1, binary s1; +s1 hex(s1) +a 0061 +ä 00E4 +ae 00610065 +o 006F +ö 00F6 +oe 006F0065 +s 0073 +ss 00730073 +ß 00DF +u 0075 +ü 00FC +ue 00750065 +select group_concat(s1 order by binary s1) from t1 group by s1; +group_concat(s1 order by binary s1) +a,ä +ae +o,ö +oe +s +ss,ß +u,ü +ue +drop table t1; +CREATE TABLE t1 AS SELECT REPEAT('a',1) AS a, 1 AS b LIMIT 0; +SHOW CREATE TABLE t1; +Table Create Table +t1 CREATE TABLE `t1` ( + `a` varchar(1) CHARACTER SET utf16 COLLATE utf16_unicode_ci NOT NULL DEFAULT '', + `b` int(1) NOT NULL DEFAULT '0' +) ENGINE=MyISAM DEFAULT CHARSET=latin1 +INSERT INTO t1 VALUES ('s',0),(_latin1 0xDF,1); +SELECT * FROM t1 ORDER BY a, b; +a b +s 0 +ß 1 +SELECT * FROM t1 ORDER BY a DESC, b; +a b +ß 1 +s 0 +SELECT * FROM t1 ORDER BY CONCAT(a), b; +a b +s 0 +ß 1 +SELECT * FROM t1 ORDER BY CONCAT(a) DESC, b; +a b +ß 1 +s 0 +DROP TABLE t1; End of 4.1 tests CREATE TABLE t1 (id int, a varchar(30) character set utf16); INSERT INTO t1 VALUES (1, 0x01310069), (2, 0x01310131); @@ -2417,3 +2477,344 @@ DROP TABLE t1; # # End of 5.5 tests # +# +# Start of 5.6 tests +# +# +# WL#3664 WEIGHT_STRING +# +set collation_connection=utf16_unicode_ci; +select @@collation_connection; +@@collation_connection +utf16_unicode_ci +select hex(weight_string('a')); +hex(weight_string('a')) +0E33 +select hex(weight_string('A')); +hex(weight_string('A')) +0E33 +select hex(weight_string('abc')); +hex(weight_string('abc')) +0E330E4A0E60 +select hex(weight_string('abc' as char(2))); +hex(weight_string('abc' as char(2))) +0E330E4A +select hex(weight_string('abc' as char(3))); +hex(weight_string('abc' as char(3))) +0E330E4A0E60 +select hex(weight_string('abc' as char(5))); +hex(weight_string('abc' as char(5))) +0E330E4A0E6002090209 +select hex(weight_string('abc', 1, 2, 0xC0)); +hex(weight_string('abc', 1, 2, 0xC0)) +0E +select hex(weight_string('abc', 2, 2, 0xC0)); +hex(weight_string('abc', 2, 2, 0xC0)) +0E33 +select hex(weight_string('abc', 3, 2, 0xC0)); +hex(weight_string('abc', 3, 2, 0xC0)) +0E330E +select hex(weight_string('abc', 4, 2, 0xC0)); +hex(weight_string('abc', 4, 2, 0xC0)) +0E330E4A +select hex(weight_string('abc', 5, 2, 0xC0)); +hex(weight_string('abc', 5, 2, 0xC0)) +0E330E4A02 +select hex(weight_string('abc',25, 2, 0xC0)); +hex(weight_string('abc',25, 2, 0xC0)) +0E330E4A020902090209020902090209020902090209020902 +select hex(weight_string('abc', 1, 3, 0xC0)); +hex(weight_string('abc', 1, 3, 0xC0)) +0E +select hex(weight_string('abc', 2, 3, 0xC0)); +hex(weight_string('abc', 2, 3, 0xC0)) +0E33 +select hex(weight_string('abc', 3, 3, 0xC0)); +hex(weight_string('abc', 3, 3, 0xC0)) +0E330E +select hex(weight_string('abc', 4, 3, 0xC0)); +hex(weight_string('abc', 4, 3, 0xC0)) +0E330E4A +select hex(weight_string('abc', 5, 3, 0xC0)); +hex(weight_string('abc', 5, 3, 0xC0)) +0E330E4A0E +select hex(weight_string('abc',25, 3, 0xC0)); +hex(weight_string('abc',25, 3, 0xC0)) +0E330E4A0E6002090209020902090209020902090209020902 +select hex(weight_string('abc', 1, 4, 0xC0)); +hex(weight_string('abc', 1, 4, 0xC0)) +0E +select hex(weight_string('abc', 2, 4, 0xC0)); +hex(weight_string('abc', 2, 4, 0xC0)) +0E33 +select hex(weight_string('abc', 3, 4, 0xC0)); +hex(weight_string('abc', 3, 4, 0xC0)) +0E330E +select hex(weight_string('abc', 4, 4, 0xC0)); +hex(weight_string('abc', 4, 4, 0xC0)) +0E330E4A +select hex(weight_string('abc', 5, 4, 0xC0)); +hex(weight_string('abc', 5, 4, 0xC0)) +0E330E4A0E +select hex(weight_string('abc',25, 4, 0xC0)); +hex(weight_string('abc',25, 4, 0xC0)) +0E330E4A0E6002090209020902090209020902090209020902 +select @@collation_connection; +@@collation_connection +utf16_unicode_ci +select hex(weight_string(cast(_latin1 0x80 as char))); +hex(weight_string(cast(_latin1 0x80 as char))) +0E23 +select hex(weight_string(cast(_latin1 0x808080 as char))); +hex(weight_string(cast(_latin1 0x808080 as char))) +0E230E230E23 +select hex(weight_string(cast(_latin1 0x808080 as char) as char(2))); +hex(weight_string(cast(_latin1 0x808080 as char) as char(2))) +0E230E23 +select hex(weight_string(cast(_latin1 0x808080 as char) as char(3))); +hex(weight_string(cast(_latin1 0x808080 as char) as char(3))) +0E230E230E23 +select hex(weight_string(cast(_latin1 0x808080 as char) as char(5))); +hex(weight_string(cast(_latin1 0x808080 as char) as char(5))) +0E230E230E2302090209 +select hex(weight_string(cast(_latin1 0x808080 as char), 1, 2, 0xC0)); +hex(weight_string(cast(_latin1 0x808080 as char), 1, 2, 0xC0)) +0E +select hex(weight_string(cast(_latin1 0x808080 as char), 2, 2, 0xC0)); +hex(weight_string(cast(_latin1 0x808080 as char), 2, 2, 0xC0)) +0E23 +select hex(weight_string(cast(_latin1 0x808080 as char), 3, 2, 0xC0)); +hex(weight_string(cast(_latin1 0x808080 as char), 3, 2, 0xC0)) +0E230E +select hex(weight_string(cast(_latin1 0x808080 as char), 4, 2, 0xC0)); +hex(weight_string(cast(_latin1 0x808080 as char), 4, 2, 0xC0)) +0E230E23 +select hex(weight_string(cast(_latin1 0x808080 as char), 5, 2, 0xC0)); +hex(weight_string(cast(_latin1 0x808080 as char), 5, 2, 0xC0)) +0E230E2302 +select hex(weight_string(cast(_latin1 0x808080 as char),25, 2, 0xC0)); +hex(weight_string(cast(_latin1 0x808080 as char),25, 2, 0xC0)) +0E230E23020902090209020902090209020902090209020902 +select hex(weight_string(cast(_latin1 0x808080 as char), 1, 3, 0xC0)); +hex(weight_string(cast(_latin1 0x808080 as char), 1, 3, 0xC0)) +0E +select hex(weight_string(cast(_latin1 0x808080 as char), 2, 3, 0xC0)); +hex(weight_string(cast(_latin1 0x808080 as char), 2, 3, 0xC0)) +0E23 +select hex(weight_string(cast(_latin1 0x808080 as char), 3, 3, 0xC0)); +hex(weight_string(cast(_latin1 0x808080 as char), 3, 3, 0xC0)) +0E230E +select hex(weight_string(cast(_latin1 0x808080 as char), 4, 3, 0xC0)); +hex(weight_string(cast(_latin1 0x808080 as char), 4, 3, 0xC0)) +0E230E23 +select hex(weight_string(cast(_latin1 0x808080 as char), 5, 3, 0xC0)); +hex(weight_string(cast(_latin1 0x808080 as char), 5, 3, 0xC0)) +0E230E230E +select hex(weight_string(cast(_latin1 0x808080 as char),25, 3, 0xC0)); +hex(weight_string(cast(_latin1 0x808080 as char),25, 3, 0xC0)) +0E230E230E2302090209020902090209020902090209020902 +select hex(weight_string(cast(_latin1 0x808080 as char), 1, 4, 0xC0)); +hex(weight_string(cast(_latin1 0x808080 as char), 1, 4, 0xC0)) +0E +select hex(weight_string(cast(_latin1 0x808080 as char), 2, 4, 0xC0)); +hex(weight_string(cast(_latin1 0x808080 as char), 2, 4, 0xC0)) +0E23 +select hex(weight_string(cast(_latin1 0x808080 as char), 3, 4, 0xC0)); +hex(weight_string(cast(_latin1 0x808080 as char), 3, 4, 0xC0)) +0E230E +select hex(weight_string(cast(_latin1 0x808080 as char), 4, 4, 0xC0)); +hex(weight_string(cast(_latin1 0x808080 as char), 4, 4, 0xC0)) +0E230E23 +select hex(weight_string(cast(_latin1 0x808080 as char), 5, 4, 0xC0)); +hex(weight_string(cast(_latin1 0x808080 as char), 5, 4, 0xC0)) +0E230E230E +select hex(weight_string(cast(_latin1 0x808080 as char),25, 4, 0xC0)); +hex(weight_string(cast(_latin1 0x808080 as char),25, 4, 0xC0)) +0E230E230E2302090209020902090209020902090209020902 +select hex(weight_string(_utf16 0xD800DC00 collate utf16_unicode_ci)); +hex(weight_string(_utf16 0xD800DC00 collate utf16_unicode_ci)) +FFFD +select hex(weight_string(_utf16 0xD800DC01 collate utf16_unicode_ci)); +hex(weight_string(_utf16 0xD800DC01 collate utf16_unicode_ci)) +FFFD +select @@collation_connection; +@@collation_connection +utf16_unicode_ci +select hex(weight_string('a' LEVEL 1)); +hex(weight_string('a' LEVEL 1)) +0E33 +select hex(weight_string('A' LEVEL 1)); +hex(weight_string('A' LEVEL 1)) +0E33 +select hex(weight_string('abc' LEVEL 1)); +hex(weight_string('abc' LEVEL 1)) +0E330E4A0E60 +select hex(weight_string('abc' as char(2) LEVEL 1)); +hex(weight_string('abc' as char(2) LEVEL 1)) +0E330E4A +select hex(weight_string('abc' as char(3) LEVEL 1)); +hex(weight_string('abc' as char(3) LEVEL 1)) +0E330E4A0E60 +select hex(weight_string('abc' as char(5) LEVEL 1)); +hex(weight_string('abc' as char(5) LEVEL 1)) +0E330E4A0E6002090209 +select hex(weight_string('abc' as char(5) LEVEL 1 REVERSE)); +hex(weight_string('abc' as char(5) LEVEL 1 REVERSE)) +09020902600E4A0E330E +select hex(weight_string('abc' as char(5) LEVEL 1 DESC)); +hex(weight_string('abc' as char(5) LEVEL 1 DESC)) +F1CCF1B5F19FFDF6FDF6 +select hex(weight_string('abc' as char(5) LEVEL 1 DESC REVERSE)); +hex(weight_string('abc' as char(5) LEVEL 1 DESC REVERSE)) +F6FDF6FD9FF1B5F1CCF1 +set @@collation_connection=utf16_czech_ci; +select @@collation_connection; +@@collation_connection +utf16_czech_ci +select collation(cast(_latin1 0xDF as char)); +collation(cast(_latin1 0xDF as char)) +utf16_czech_ci +select hex(weight_string('s')); +hex(weight_string('s')) +0FEA +select hex(weight_string(cast(_latin1 0xDF as char))); +hex(weight_string(cast(_latin1 0xDF as char))) +0FEA0FEA +select hex(weight_string(cast(_latin1 0xDF as char) as char(1))); +hex(weight_string(cast(_latin1 0xDF as char) as char(1))) +0FEA +select hex(weight_string('c')); +hex(weight_string('c')) +0E60 +select hex(weight_string('h')); +hex(weight_string('h')) +0EE1 +select hex(weight_string('ch')); +hex(weight_string('ch')) +0EE2 +select hex(weight_string('i')); +hex(weight_string('i')) +0EFB +select hex(weight_string(cast(_latin1 0x6368DF as char))); +hex(weight_string(cast(_latin1 0x6368DF as char))) +0EE20FEA0FEA +select hex(weight_string(cast(_latin1 0x6368DF as char) as char(1))); +hex(weight_string(cast(_latin1 0x6368DF as char) as char(1))) +0EE2 +select hex(weight_string(cast(_latin1 0x6368DF as char) as char(2))); +hex(weight_string(cast(_latin1 0x6368DF as char) as char(2))) +0EE20FEA +select hex(weight_string(cast(_latin1 0x6368DF as char) as char(3))); +hex(weight_string(cast(_latin1 0x6368DF as char) as char(3))) +0EE20FEA0FEA +select hex(weight_string(cast(_latin1 0x6368DF as char) as char(4))); +hex(weight_string(cast(_latin1 0x6368DF as char) as char(4))) +0EE20FEA0FEA0209 +select hex(weight_string(cast(_latin1 0xDF6368 as char))); +hex(weight_string(cast(_latin1 0xDF6368 as char))) +0FEA0FEA0EE2 +select hex(weight_string(cast(_latin1 0xDF6368 as char) as char(1))); +hex(weight_string(cast(_latin1 0xDF6368 as char) as char(1))) +0FEA +select hex(weight_string(cast(_latin1 0xDF6368 as char) as char(2))); +hex(weight_string(cast(_latin1 0xDF6368 as char) as char(2))) +0FEA0FEA +select hex(weight_string(cast(_latin1 0xDF6368 as char) as char(3))); +hex(weight_string(cast(_latin1 0xDF6368 as char) as char(3))) +0FEA0FEA0EE2 +select hex(weight_string(cast(_latin1 0xDF6368 as char) as char(4))); +hex(weight_string(cast(_latin1 0xDF6368 as char) as char(4))) +0FEA0FEA0EE20209 +select hex(weight_string(cast(_latin1 0x6368DF as char), 1, 2, 0xC0)); +hex(weight_string(cast(_latin1 0x6368DF as char), 1, 2, 0xC0)) +0E +select hex(weight_string(cast(_latin1 0x6368DF as char), 2, 2, 0xC0)); +hex(weight_string(cast(_latin1 0x6368DF as char), 2, 2, 0xC0)) +0EE2 +select hex(weight_string(cast(_latin1 0x6368DF as char), 3, 2, 0xC0)); +hex(weight_string(cast(_latin1 0x6368DF as char), 3, 2, 0xC0)) +0EE20F +select hex(weight_string(cast(_latin1 0x6368DF as char), 4, 2, 0xC0)); +hex(weight_string(cast(_latin1 0x6368DF as char), 4, 2, 0xC0)) +0EE20FEA +select hex(weight_string(cast(_latin1 0x6368DF as char),25, 2, 0xC0)); +hex(weight_string(cast(_latin1 0x6368DF as char),25, 2, 0xC0)) +0EE20FEA020902090209020902090209020902090209020902 +select hex(weight_string(cast(_latin1 0x6368DF as char), 1, 3, 0xC0)); +hex(weight_string(cast(_latin1 0x6368DF as char), 1, 3, 0xC0)) +0E +select hex(weight_string(cast(_latin1 0x6368DF as char), 2, 3, 0xC0)); +hex(weight_string(cast(_latin1 0x6368DF as char), 2, 3, 0xC0)) +0EE2 +select hex(weight_string(cast(_latin1 0x6368DF as char), 3, 3, 0xC0)); +hex(weight_string(cast(_latin1 0x6368DF as char), 3, 3, 0xC0)) +0EE20F +select hex(weight_string(cast(_latin1 0x6368DF as char), 4, 3, 0xC0)); +hex(weight_string(cast(_latin1 0x6368DF as char), 4, 3, 0xC0)) +0EE20FEA +select hex(weight_string(cast(_latin1 0x6368DF as char),25, 3, 0xC0)); +hex(weight_string(cast(_latin1 0x6368DF as char),25, 3, 0xC0)) +0EE20FEA0FEA02090209020902090209020902090209020902 +select hex(weight_string(cast(_latin1 0x6368DF as char), 1, 4, 0xC0)); +hex(weight_string(cast(_latin1 0x6368DF as char), 1, 4, 0xC0)) +0E +select hex(weight_string(cast(_latin1 0x6368DF as char), 2, 4, 0xC0)); +hex(weight_string(cast(_latin1 0x6368DF as char), 2, 4, 0xC0)) +0EE2 +select hex(weight_string(cast(_latin1 0x6368DF as char), 3, 4, 0xC0)); +hex(weight_string(cast(_latin1 0x6368DF as char), 3, 4, 0xC0)) +0EE20F +select hex(weight_string(cast(_latin1 0x6368DF as char), 4, 4, 0xC0)); +hex(weight_string(cast(_latin1 0x6368DF as char), 4, 4, 0xC0)) +0EE20FEA +select hex(weight_string(cast(_latin1 0x6368DF as char),25, 4, 0xC0)); +hex(weight_string(cast(_latin1 0x6368DF as char),25, 4, 0xC0)) +0EE20FEA0FEA02090209020902090209020902090209020902 +select hex(weight_string(cast(_latin1 0xDF6368 as char), 1, 2,0xC0)); +hex(weight_string(cast(_latin1 0xDF6368 as char), 1, 2,0xC0)) +0F +select hex(weight_string(cast(_latin1 0xDF6368 as char), 2, 2,0xC0)); +hex(weight_string(cast(_latin1 0xDF6368 as char), 2, 2,0xC0)) +0FEA +select hex(weight_string(cast(_latin1 0xDF6368 as char), 3, 2,0xC0)); +hex(weight_string(cast(_latin1 0xDF6368 as char), 3, 2,0xC0)) +0FEA0F +select hex(weight_string(cast(_latin1 0xDF6368 as char), 4, 2,0xC0)); +hex(weight_string(cast(_latin1 0xDF6368 as char), 4, 2,0xC0)) +0FEA0FEA +select hex(weight_string(cast(_latin1 0xDF6368 as char),25, 2,0xC0)); +hex(weight_string(cast(_latin1 0xDF6368 as char),25, 2,0xC0)) +0FEA0FEA020902090209020902090209020902090209020902 +select hex(weight_string(cast(_latin1 0xDF6368 as char), 1, 3,0xC0)); +hex(weight_string(cast(_latin1 0xDF6368 as char), 1, 3,0xC0)) +0F +select hex(weight_string(cast(_latin1 0xDF6368 as char), 2, 3,0xC0)); +hex(weight_string(cast(_latin1 0xDF6368 as char), 2, 3,0xC0)) +0FEA +select hex(weight_string(cast(_latin1 0xDF6368 as char), 3, 3,0xC0)); +hex(weight_string(cast(_latin1 0xDF6368 as char), 3, 3,0xC0)) +0FEA0F +select hex(weight_string(cast(_latin1 0xDF6368 as char), 4, 3,0xC0)); +hex(weight_string(cast(_latin1 0xDF6368 as char), 4, 3,0xC0)) +0FEA0FEA +select hex(weight_string(cast(_latin1 0xDF6368 as char),25, 3,0xC0)); +hex(weight_string(cast(_latin1 0xDF6368 as char),25, 3,0xC0)) +0FEA0FEA0EE202090209020902090209020902090209020902 +select hex(weight_string(cast(_latin1 0xDF6368 as char), 1, 4,0xC0)); +hex(weight_string(cast(_latin1 0xDF6368 as char), 1, 4,0xC0)) +0F +select hex(weight_string(cast(_latin1 0xDF6368 as char), 2, 4,0xC0)); +hex(weight_string(cast(_latin1 0xDF6368 as char), 2, 4,0xC0)) +0FEA +select hex(weight_string(cast(_latin1 0xDF6368 as char), 3, 4,0xC0)); +hex(weight_string(cast(_latin1 0xDF6368 as char), 3, 4,0xC0)) +0FEA0F +select hex(weight_string(cast(_latin1 0xDF6368 as char), 4, 4,0xC0)); +hex(weight_string(cast(_latin1 0xDF6368 as char), 4, 4,0xC0)) +0FEA0FEA +select hex(weight_string(cast(_latin1 0xDF6368 as char),25, 4,0xC0)); +hex(weight_string(cast(_latin1 0xDF6368 as char),25, 4,0xC0)) +0FEA0FEA0EE202090209020902090209020902090209020902 +# +# End of 5.6 tests +# |