summaryrefslogtreecommitdiff
path: root/mysql-test
diff options
context:
space:
mode:
authorMichael Widenius <monty@askmonty.org>2013-11-09 00:20:07 +0200
committerMichael Widenius <monty@askmonty.org>2013-11-09 00:20:07 +0200
commit192678e7bf57eba9710c3000a7d0b6711380d545 (patch)
tree53269f3c073b706d74335ded6029724f7fa5d7b9 /mysql-test
parent273bcb92c1c126bc9cfa973d925b8e1da1b3c1bb (diff)
downloadmariadb-git-192678e7bf57eba9710c3000a7d0b6711380d545.tar.gz
MDEV-5241: Collation incompatibilities with MySQL-5.6
- Character set code & tests from Alexander Barkov - Integration with ALTER TABLE, REPAIR and open_table from Monty The problem was that MySQL 5.6 added some croatian and vitanamese character set collations that are incompatible with MariaDB. The fix is to move the MariaDB conflicting collation numbers out of the region that MySQL is likely to use. mysql_upgrade, REPAIR TABLE or ALTER TABLE will fix the collations. If one tries to access and old incompatible table, one will get the error "Table upgrade required...." After this patch, MariaDB supports all the MySQL character set collations and the old MariaDB croatian collations, which are closer to the latest standard than the MySQL versions. New character sets: ucs2_croatian_mysql561_uca_ci utf8_croatian_mysql561_uca_ci utf16_croatian_mysql561_uca_ci utf32_croatian_mysql561_uca_ci utf8mb4_croatian_mysql561_uca_ci Other things: - Fixed some compiler warnings - mysql_upgrade prints information about repaired tables. - Increased version number VERSION: Increased VERSION number client/mysqlcheck.c: Print repaired table name when using --verbose include/m_ctype.h: Add new MariaDB collation regions that are not likely to conflict with MySQL include/my_base.h: Added flag to detect if table was opened for ALTER TABLE mysql-test/r/ctype_ldml.result: Updated result mysql-test/r/ctype_uca.result: Updated result mysql-test/r/ctype_upgrade.result: Updated result mysql-test/r/ctype_utf16_uca.result: Updated result mysql-test/r/ctype_utf32_uca.result: Updated result mysql-test/r/ctype_utf8mb4_uca.result: Updated result mysql-test/std_data/ctype_upgrade: Test files for testing upgrading of conflicting collations mysql-test/suite/engines/funcs/r/db_alter_collate_ascii.result: New collations added mysql-test/suite/engines/funcs/r/db_alter_collate_utf8.result: New collations added mysql-test/suite/innodb/r/innodb_ctype_ldml.result: Updated test result mysql-test/suite/innodb/t/innodb_ctype_ldml.test: Updated test result mysql-test/suite/plugins/r/show_all_plugins.result: Updated version number mysql-test/suite/roles/create_and_drop_role_invalid_user_table.result: Updated version number mysql-test/t/ctype_ldml.test: Updated test mysql-test/t/ctype_uca.test: Testing of new collations mysql-test/t/ctype_upgrade.test: Testing of upgrading tables with old collations The test ensures that: - We will get an error if we try to open a table with old collations. - CHECK TABLE will detect that the table needs to be upgraded. - ALTER TABLE and REPAIR will fix the table. - mysql_upgrade works as expected mysql-test/t/ctype_utf16_uca.test: Testing of new collations mysql-test/t/ctype_utf32_uca.test: Testing of new collations mysql-test/t/ctype_utf8mb4_uca.test: Testing of new collations mysys/charset-def.c: Added new character sets mysys/charset.c: Always give an error, if requested, if a character set didn't exist sql/handler.cc: - Added upgrade_collation() to check if collation is compatible with old version - check_collation_compatibility() checks if we are using an old collation from MariaDB 5.5 or MySQL 5.6 - ha_check_for_upgrade() returns HA_ADMIN_NEEDS_ALTER if we have an incompatible collation sql/handler.h: Added new prototypes sql/sql_table.cc: - Mark that tables are opened for ALTER TABLE - If table needs to be upgraded, ensure we are not using online alter table. sql/table.cc: - If we are using an old incompatible collation, change to use the new one and mark table as incompatible. - Give an error if we try to open an incompatible table. sql/table.h: Added error that table needs to be rebuild storage/connect/ha_connect.cc: Fixed compiler warning strings/ctype-uca.c: New character sets
Diffstat (limited to 'mysql-test')
-rw-r--r--mysql-test/r/ctype_ldml.result2
-rw-r--r--mysql-test/r/ctype_uca.result228
-rw-r--r--mysql-test/r/ctype_upgrade.result389
-rw-r--r--mysql-test/r/ctype_utf16_uca.result110
-rw-r--r--mysql-test/r/ctype_utf32_uca.result110
-rw-r--r--mysql-test/r/ctype_utf8mb4_uca.result110
-rw-r--r--mysql-test/std_data/ctype_upgrade/maria050313_ucs2_croatian_ci_def.MYDbin0 -> 21 bytes
-rw-r--r--mysql-test/std_data/ctype_upgrade/maria050313_ucs2_croatian_ci_def.MYIbin0 -> 1024 bytes
-rw-r--r--mysql-test/std_data/ctype_upgrade/maria050313_ucs2_croatian_ci_def.frmbin0 -> 8554 bytes
-rw-r--r--mysql-test/std_data/ctype_upgrade/maria050313_utf8_croatian_ci.MYDbin0 -> 80 bytes
-rw-r--r--mysql-test/std_data/ctype_upgrade/maria050313_utf8_croatian_ci.MYIbin0 -> 1024 bytes
-rw-r--r--mysql-test/std_data/ctype_upgrade/maria050313_utf8_croatian_ci.frmbin0 -> 8554 bytes
-rw-r--r--mysql-test/std_data/ctype_upgrade/maria050533_xxx_croatian_ci.MYDbin0 -> 176 bytes
-rw-r--r--mysql-test/std_data/ctype_upgrade/maria050533_xxx_croatian_ci.MYIbin0 -> 1024 bytes
-rw-r--r--mysql-test/std_data/ctype_upgrade/maria050533_xxx_croatian_ci.frmbin0 -> 8650 bytes
-rw-r--r--mysql-test/std_data/ctype_upgrade/maria100004_xxx_croatian_ci.MYDbin0 -> 176 bytes
-rw-r--r--mysql-test/std_data/ctype_upgrade/maria100004_xxx_croatian_ci.MYIbin0 -> 1024 bytes
-rw-r--r--mysql-test/std_data/ctype_upgrade/maria100004_xxx_croatian_ci.frmbin0 -> 679 bytes
-rw-r--r--mysql-test/std_data/ctype_upgrade/mysql050614_xxx_croatian_ci.MYDbin0 -> 176 bytes
-rw-r--r--mysql-test/std_data/ctype_upgrade/mysql050614_xxx_croatian_ci.MYIbin0 -> 1024 bytes
-rw-r--r--mysql-test/std_data/ctype_upgrade/mysql050614_xxx_croatian_ci.frmbin0 -> 8650 bytes
-rw-r--r--mysql-test/suite/engines/funcs/r/db_alter_collate_ascii.result15
-rw-r--r--mysql-test/suite/engines/funcs/r/db_alter_collate_utf8.result15
-rw-r--r--mysql-test/suite/innodb/r/innodb_ctype_ldml.result2
-rw-r--r--mysql-test/suite/innodb/t/innodb_ctype_ldml.test2
-rw-r--r--mysql-test/suite/plugins/r/show_all_plugins.result4
-rw-r--r--mysql-test/suite/roles/create_and_drop_role_invalid_user_table.result2
-rw-r--r--mysql-test/t/ctype_ldml.test2
-rw-r--r--mysql-test/t/ctype_uca.test4
-rw-r--r--mysql-test/t/ctype_upgrade.test198
-rw-r--r--mysql-test/t/ctype_utf16_uca.test1
-rw-r--r--mysql-test/t/ctype_utf32_uca.test1
-rw-r--r--mysql-test/t/ctype_utf8mb4_uca.test1
33 files changed, 1175 insertions, 21 deletions
diff --git a/mysql-test/r/ctype_ldml.result b/mysql-test/r/ctype_ldml.result
index bd96a1f6255..932df0322db 100644
--- a/mysql-test/r/ctype_ldml.result
+++ b/mysql-test/r/ctype_ldml.result
@@ -407,7 +407,7 @@ select "foo" = "foo " collate latin1_test;
"foo" = "foo " collate latin1_test
1
The following tests check that two-byte collation IDs work
-select * from information_schema.collations where id>256 order by id;
+select * from information_schema.collations where id>256 and is_compiled<>'Yes' order by id;
COLLATION_NAME CHARACTER_SET_NAME ID IS_DEFAULT IS_COMPILED SORTLEN
utf8mb4_test_ci utf8mb4 326 8
utf16_test_ci utf16 327 8
diff --git a/mysql-test/r/ctype_uca.result b/mysql-test/r/ctype_uca.result
index 29099a581ef..b67fb8fdc98 100644
--- a/mysql-test/r/ctype_uca.result
+++ b/mysql-test/r/ctype_uca.result
@@ -2168,6 +2168,116 @@ Z,z,Ź,ź,Ż,ż,Ž,ž
ǁ
ǂ
ǃ
+select group_concat(c1 order by c1) from t1 group by c1 collate utf8_croatian_mysql561_ci;
+group_concat(c1 order by c1)
+A,a,À,Á,Â,Ã,Ä,Å,à,á,â,ã,ä,å,Ā,ā,Ă,ă,Ą,ą,Ǎ,ǎ,Ǟ,ǟ,Ǡ,ǡ,Ǻ,ǻ,Ạ,ạ,Ả,ả,Ấ,ấ,Ầ,ầ,Ẩ,ẩ,Ẫ,ẫ,Ậ,ậ,Ắ,ắ,Ằ,ằ,Ẳ,ẳ,Ẵ,ẵ,Ặ,ặ
+AA,Aa,aA,aa
+AE,Ae,aE,ae
+Æ,æ,Ǣ,ǣ,Ǽ,ǽ
+B,b
+Ƃ,ƃ
+C,c,Ç,ç,Ĉ,ĉ,Ċ,ċ
+CH,Ch,cH,ch
+Č,č
+Ć,ć
+Ƈ,ƈ
+D,d,Ď,ď
+DZ,Dz,dZ,dz,DZ,Dz,dz
+DŽ,Dž,dŽ,dž,DŽ,Dž,dž
+Đ,đ
+Ƌ,ƌ
+Ð,ð
+E,e,È,É,Ê,Ë,è,é,ê,ë,Ē,ē,Ĕ,ĕ,Ė,ė,Ę,ę,Ě,ě,Ẹ,ẹ,Ẻ,ẻ,Ẽ,ẽ,Ế,ế,Ề,ề,Ể,ể,Ễ,ễ,Ệ,ệ
+Ǝ,ǝ
+F,f
+Ƒ,ƒ
+G,g,Ĝ,ĝ,Ğ,ğ,Ġ,ġ,Ģ,ģ,Ǧ,ǧ,Ǵ,ǵ
+Ǥ,ǥ
+Ƣ,ƣ
+H,h,Ĥ,ĥ
+ƕ,Ƕ
+Ħ,ħ
+I,i,Ì,Í,Î,Ï,ì,í,î,ï,Ĩ,ĩ,Ī,ī,Ĭ,ĭ,Į,į,İ,Ǐ,ǐ,Ỉ,ỉ,Ị,ị
+IJ,Ij,iJ,ij,IJ,ij
+J,j,Ĵ,ĵ,ǰ
+K,k,Ķ,ķ,Ǩ,ǩ
+Ƙ,ƙ
+L,l,Ĺ,ĺ,Ļ,ļ,Ľ,ľ
+Ŀ,ŀ
+LL,Ll,lL,ll
+LJ,Lj,lJ,lj,LJ,Lj,lj
+Ł,ł
+M,m
+N,n,Ñ,ñ,Ń,ń,Ņ,ņ,Ň,ň,Ǹ,ǹ
+NJ,Nj,nJ,nj,NJ,Nj,nj
+Ŋ,ŋ
+O,o,Ò,Ó,Ô,Õ,Ö,ò,ó,ô,õ,ö,Ō,ō,Ŏ,ŏ,Ő,ő,Ơ,ơ,Ǒ,ǒ,Ǫ,ǫ,Ǭ,ǭ,Ọ,ọ,Ỏ,ỏ,Ố,ố,Ồ,ồ,Ổ,ổ,Ỗ,ỗ,Ộ,ộ,Ớ,ớ,Ờ,ờ,Ở,ở,Ỡ,ỡ,Ợ,ợ
+OE,Oe,oE,oe,Œ,œ
+Ø,ø,Ǿ,ǿ
+P,p
+Ƥ,ƥ
+Q,q
+R,r,Ŕ,ŕ,Ŗ,ŗ,Ř,ř
+RR,Rr,rR,rr
+S,s,Ś,ś,Ŝ,ŝ,Ş,ş,ſ
+SS,Ss,sS,ss,ß
+Š,š
+T,t,Ţ,ţ,Ť,ť
+Ŧ,ŧ
+Ƭ,ƭ
+U,u,Ù,Ú,Û,Ü,ù,ú,û,ü,Ũ,ũ,Ū,ū,Ŭ,ŭ,Ů,ů,Ű,ű,Ų,ų,Ư,ư,Ǔ,ǔ,Ǖ,ǖ,Ǘ,ǘ,Ǚ,ǚ,Ǜ,ǜ,Ụ,ụ,Ủ,ủ,Ứ,ứ,Ừ,ừ,Ử,ử,Ữ,ữ,Ự,ự
+V,v
+W,w,Ŵ,ŵ
+X,x
+Y,y,Ý,ý,ÿ,Ŷ,ŷ,Ÿ
+Ƴ,ƴ
+Z,z,Ź,ź,Ż,ż
+Ž,ž
+Ƶ,ƶ
+Ʒ,Ǯ,ǯ
+Ƹ,ƹ
+Þ,þ
+ƿ,Ƿ
+Ƨ,ƨ
+Ƽ,ƽ
+Ƅ,ƅ
select group_concat(c1 order by c1) from t1 group by c1 collate utf8_croatian_ci;
group_concat(c1 order by c1)
÷
@@ -4367,6 +4477,116 @@ Z,z,Ź,ź,Ż,ż,Ž,ž
ǁ
ǂ
ǃ
+SELECT GROUP_CONCAT(c1 ORDER BY c1) FROM t1 GROUP BY c1 COLLATE ucs2_croatian_mysql561_ci;
+GROUP_CONCAT(c1 ORDER BY c1)
+A,a,À,Á,Â,Ã,Ä,Å,à,á,â,ã,ä,å,Ā,ā,Ă,ă,Ą,ą,Ǎ,ǎ,Ǟ,ǟ,Ǡ,ǡ,Ǻ,ǻ,Ạ,ạ,Ả,ả,Ấ,ấ,Ầ,ầ,Ẩ,ẩ,Ẫ,ẫ,Ậ,ậ,Ắ,ắ,Ằ,ằ,Ẳ,ẳ,Ẵ,ẵ,Ặ,ặ
+AA,Aa,aA,aa
+AE,Ae,aE,ae
+Æ,æ,Ǣ,ǣ,Ǽ,ǽ
+B,b
+Ƃ,ƃ
+C,c,Ç,ç,Ĉ,ĉ,Ċ,ċ
+CH,Ch,cH,ch
+Č,č
+Ć,ć
+Ƈ,ƈ
+D,d,Ď,ď
+DZ,Dz,dZ,dz,DZ,Dz,dz
+DŽ,Dž,dŽ,dž,DŽ,Dž,dž
+Đ,đ
+Ƌ,ƌ
+Ð,ð
+E,e,È,É,Ê,Ë,è,é,ê,ë,Ē,ē,Ĕ,ĕ,Ė,ė,Ę,ę,Ě,ě,Ẹ,ẹ,Ẻ,ẻ,Ẽ,ẽ,Ế,ế,Ề,ề,Ể,ể,Ễ,ễ,Ệ,ệ
+Ǝ,ǝ
+F,f
+Ƒ,ƒ
+G,g,Ĝ,ĝ,Ğ,ğ,Ġ,ġ,Ģ,ģ,Ǧ,ǧ,Ǵ,ǵ
+Ǥ,ǥ
+Ƣ,ƣ
+H,h,Ĥ,ĥ
+ƕ,Ƕ
+Ħ,ħ
+I,i,Ì,Í,Î,Ï,ì,í,î,ï,Ĩ,ĩ,Ī,ī,Ĭ,ĭ,Į,į,İ,Ǐ,ǐ,Ỉ,ỉ,Ị,ị
+IJ,Ij,iJ,ij,IJ,ij
+J,j,Ĵ,ĵ,ǰ
+K,k,Ķ,ķ,Ǩ,ǩ
+Ƙ,ƙ
+L,l,Ĺ,ĺ,Ļ,ļ,Ľ,ľ
+Ŀ,ŀ
+LL,Ll,lL,ll
+LJ,Lj,lJ,lj,LJ,Lj,lj
+Ł,ł
+M,m
+N,n,Ñ,ñ,Ń,ń,Ņ,ņ,Ň,ň,Ǹ,ǹ
+NJ,Nj,nJ,nj,NJ,Nj,nj
+Ŋ,ŋ
+O,o,Ò,Ó,Ô,Õ,Ö,ò,ó,ô,õ,ö,Ō,ō,Ŏ,ŏ,Ő,ő,Ơ,ơ,Ǒ,ǒ,Ǫ,ǫ,Ǭ,ǭ,Ọ,ọ,Ỏ,ỏ,Ố,ố,Ồ,ồ,Ổ,ổ,Ỗ,ỗ,Ộ,ộ,Ớ,ớ,Ờ,ờ,Ở,ở,Ỡ,ỡ,Ợ,ợ
+OE,Oe,oE,oe,Œ,œ
+Ø,ø,Ǿ,ǿ
+P,p
+Ƥ,ƥ
+Q,q
+R,r,Ŕ,ŕ,Ŗ,ŗ,Ř,ř
+RR,Rr,rR,rr
+S,s,Ś,ś,Ŝ,ŝ,Ş,ş,ſ
+SS,Ss,sS,ss,ß
+Š,š
+T,t,Ţ,ţ,Ť,ť
+Ŧ,ŧ
+Ƭ,ƭ
+U,u,Ù,Ú,Û,Ü,ù,ú,û,ü,Ũ,ũ,Ū,ū,Ŭ,ŭ,Ů,ů,Ű,ű,Ų,ų,Ư,ư,Ǔ,ǔ,Ǖ,ǖ,Ǘ,ǘ,Ǚ,ǚ,Ǜ,ǜ,Ụ,ụ,Ủ,ủ,Ứ,ứ,Ừ,ừ,Ử,ử,Ữ,ữ,Ự,ự
+V,v
+W,w,Ŵ,ŵ
+X,x
+Y,y,Ý,ý,ÿ,Ŷ,ŷ,Ÿ
+Ƴ,ƴ
+Z,z,Ź,ź,Ż,ż
+Ž,ž
+Ƶ,ƶ
+Ʒ,Ǯ,ǯ
+Ƹ,ƹ
+Þ,þ
+ƿ,Ƿ
+Ƨ,ƨ
+Ƽ,ƽ
+Ƅ,ƅ
SELECT GROUP_CONCAT(c1 ORDER BY c1) FROM t1 GROUP BY c1 COLLATE ucs2_croatian_ci;
GROUP_CONCAT(c1 ORDER BY c1)
÷
@@ -5661,7 +5881,7 @@ HEX(s1)
0061000000000000000000000009
0061
DROP TABLE t1;
-create table t1 (a int, c1 varchar(200) collate utf8_croatian_ci, key (c1));
+create table t1 (a int, c1 varchar(200) collate utf8_croatian_mysql561_ci, key (c1));
insert into t1 values (1,'=> DZ'),(2,'=> Dz'),(3,'=> dz'),(4,'=> dZ');
insert into t1 values (5,'=> DŽ'),(6,'=> Dž'),(7,'=> dž'),(8,'=> dŽ');
insert into t1 values (9,'=> dž'),(10,'=> DŽ');
@@ -5671,10 +5891,10 @@ c1
=> Dz
=> dz
=> dZ
-=> dŽ
=> DŽ
=> Dž
=> dž
+=> dŽ
=> dž
=> DŽ
select concat(c1) from t1 order by c1;
@@ -5683,10 +5903,10 @@ concat(c1)
=> Dz
=> dz
=> dZ
-=> dŽ
=> DŽ
=> Dž
=> dž
+=> dŽ
=> dž
=> DŽ
select * from t1 where c1 like '=> d%';
@@ -5738,6 +5958,7 @@ a c1
5 => DŽ
6 => Dž
7 => dž
+8 => dŽ
9 => dž
10 => DŽ
select * from t1 where concat(c1) = '=> dž';
@@ -5745,6 +5966,7 @@ a c1
5 => DŽ
6 => Dž
7 => dž
+8 => dŽ
9 => dž
10 => DŽ
drop table t1;
diff --git a/mysql-test/r/ctype_upgrade.result b/mysql-test/r/ctype_upgrade.result
new file mode 100644
index 00000000000..0fc73203494
--- /dev/null
+++ b/mysql-test/r/ctype_upgrade.result
@@ -0,0 +1,389 @@
+call mtr.add_suppression("Table rebuild required");
+#
+# Upgrade from Maria-5.3.13:
+# Checking utf8_croatian_ci in a VARCHAR column
+#
+# Copying maria050313_utf8_croatian_ci.* to MYSQLD_DATADIR
+CHECK TABLE maria050313_utf8_croatian_ci FOR UPGRADE;
+Table Op Msg_type Msg_text
+test.maria050313_utf8_croatian_ci check error Table upgrade required. Please do "REPAIR TABLE `maria050313_utf8_croatian_ci`" or dump/reload to fix it!
+SHOW CREATE TABLE maria050313_utf8_croatian_ci;
+ERROR HY000: Table rebuild required. Please do "ALTER TABLE `test.maria050313_utf8_croatian_c` FORCE" or dump/reload to fix it!
+REPAIR TABLE maria050313_utf8_croatian_ci;
+Table Op Msg_type Msg_text
+test.maria050313_utf8_croatian_ci repair status OK
+CHECK TABLE maria050313_utf8_croatian_ci FOR UPGRADE;
+Table Op Msg_type Msg_text
+test.maria050313_utf8_croatian_ci check status OK
+SHOW CREATE TABLE maria050313_utf8_croatian_ci;
+Table Create Table
+maria050313_utf8_croatian_ci CREATE TABLE `maria050313_utf8_croatian_ci` (
+ `a` varchar(10) CHARACTER SET utf8 COLLATE utf8_croatian_ci DEFAULT NULL
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
+SELECT count(*) FROM maria050313_utf8_croatian_ci;
+count(*)
+4
+DROP TABLE maria050313_utf8_croatian_ci;
+# Copying maria050313_utf8_croatian_ci.* to MYSQLD_DATADIR
+ALTER TABLE maria050313_utf8_croatian_ci FORCE;
+SHOW CREATE TABLE maria050313_utf8_croatian_ci;
+Table Create Table
+maria050313_utf8_croatian_ci CREATE TABLE `maria050313_utf8_croatian_ci` (
+ `a` varchar(10) CHARACTER SET utf8 COLLATE utf8_croatian_ci DEFAULT NULL
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
+SELECT GROUP_CONCAT(a ORDER BY BINARY a) FROM maria050313_utf8_croatian_ci GROUP BY a;
+GROUP_CONCAT(a ORDER BY BINARY a)
+nJ
+NJ,Nj,nj
+DROP TABLE maria050313_utf8_croatian_ci;
+#
+# Upgrade from Maria-5.3.13:
+# Checking ucs2_croatian_ci in the table default collation
+#
+# Copying maria050313_ucs2_croatian_ci.* to MYSQLD_DATADIR
+CHECK TABLE maria050313_ucs2_croatian_ci_def FOR UPGRADE;
+Table Op Msg_type Msg_text
+test.maria050313_ucs2_croatian_ci_def check error Table upgrade required. Please do "REPAIR TABLE `maria050313_ucs2_croatian_ci_def`" or dump/reload to fix it!
+SELECT count(*) FROM maria050313_ucs2_croatian_ci_def;
+ERROR HY000: Table rebuild required. Please do "ALTER TABLE `test.maria050313_ucs2_croatian_c` FORCE" or dump/reload to fix it!
+REPAIR TABLE maria050313_ucs2_croatian_ci_def;
+Table Op Msg_type Msg_text
+test.maria050313_ucs2_croatian_ci_def repair status OK
+SHOW CREATE TABLE maria050313_ucs2_croatian_ci_def;
+Table Create Table
+maria050313_ucs2_croatian_ci_def CREATE TABLE `maria050313_ucs2_croatian_ci_def` (
+ `a` int(11) DEFAULT NULL
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_croatian_ci
+DROP TABLE maria050313_ucs2_croatian_ci_def;
+# Copying maria050313_ucs2_croatian_ci.* to MYSQLD_DATADIR
+CHECK TABLE maria050313_ucs2_croatian_ci_def;
+Table Op Msg_type Msg_text
+test.maria050313_ucs2_croatian_ci_def check error Table upgrade required. Please do "REPAIR TABLE `maria050313_ucs2_croatian_ci_def`" or dump/reload to fix it!
+REPAIR TABLE maria050313_ucs2_croatian_ci_def;
+Table Op Msg_type Msg_text
+test.maria050313_ucs2_croatian_ci_def repair status OK
+CHECK TABLE maria050313_ucs2_croatian_ci_def;
+Table Op Msg_type Msg_text
+test.maria050313_ucs2_croatian_ci_def check status OK
+SHOW CREATE TABLE maria050313_ucs2_croatian_ci_def;
+Table Create Table
+maria050313_ucs2_croatian_ci_def CREATE TABLE `maria050313_ucs2_croatian_ci_def` (
+ `a` int(11) DEFAULT NULL
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_croatian_ci
+SELECT * FROM maria050313_ucs2_croatian_ci_def ORDER BY a;
+a
+1
+2
+3
+DROP TABLE maria050313_ucs2_croatian_ci_def;
+#
+# Upgrade from Maria-5.5.33
+# Checking utf8_croatian_ci, utf8mb4_croatian_ci, ucs2_croatian_ci,
+# utf16_croatian_ci, utf32_croatian_ci
+#
+# Copying maria050533_xxx_croatian_ci.* to MYSQLD_DATADIR
+CHECK TABLE maria050533_xxx_croatian_ci FOR UPGRADE;
+Table Op Msg_type Msg_text
+test.maria050533_xxx_croatian_ci check error Table upgrade required. Please do "REPAIR TABLE `maria050533_xxx_croatian_ci`" or dump/reload to fix it!
+REPAIR TABLE maria050533_xxx_croatian_ci;
+Table Op Msg_type Msg_text
+test.maria050533_xxx_croatian_ci repair status OK
+SHOW CREATE TABLE maria050533_xxx_croatian_ci;
+Table Create Table
+maria050533_xxx_croatian_ci CREATE TABLE `maria050533_xxx_croatian_ci` (
+ `a` varchar(10) CHARACTER SET utf8 COLLATE utf8_croatian_ci DEFAULT NULL,
+ `b` varchar(10) CHARACTER SET utf8mb4 COLLATE utf8mb4_croatian_ci DEFAULT NULL,
+ `c` varchar(10) CHARACTER SET ucs2 COLLATE ucs2_croatian_ci DEFAULT NULL,
+ `d` varchar(10) CHARACTER SET utf16 COLLATE utf16_croatian_ci DEFAULT NULL,
+ `e` varchar(10) CHARACTER SET utf32 COLLATE utf32_croatian_ci DEFAULT NULL
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
+SELECT count(*) FROM maria050533_xxx_croatian_ci;
+count(*)
+4
+DROP TABLE maria050533_xxx_croatian_ci;
+# Copying maria050533_xxx_croatian_ci.* to MYSQLD_DATADIR
+ALTER TABLE maria050533_xxx_croatian_ci FORCE;
+SHOW CREATE TABLE maria050533_xxx_croatian_ci;
+Table Create Table
+maria050533_xxx_croatian_ci CREATE TABLE `maria050533_xxx_croatian_ci` (
+ `a` varchar(10) CHARACTER SET utf8 COLLATE utf8_croatian_ci DEFAULT NULL,
+ `b` varchar(10) CHARACTER SET utf8mb4 COLLATE utf8mb4_croatian_ci DEFAULT NULL,
+ `c` varchar(10) CHARACTER SET ucs2 COLLATE ucs2_croatian_ci DEFAULT NULL,
+ `d` varchar(10) CHARACTER SET utf16 COLLATE utf16_croatian_ci DEFAULT NULL,
+ `e` varchar(10) CHARACTER SET utf32 COLLATE utf32_croatian_ci DEFAULT NULL
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
+SELECT GROUP_CONCAT(a ORDER BY BINARY a) FROM maria050533_xxx_croatian_ci GROUP BY a;
+GROUP_CONCAT(a ORDER BY BINARY a)
+nJ
+NJ,Nj,nj
+SELECT GROUP_CONCAT(b ORDER BY BINARY b) FROM maria050533_xxx_croatian_ci GROUP BY b;
+GROUP_CONCAT(b ORDER BY BINARY b)
+nJ
+NJ,Nj,nj
+SELECT GROUP_CONCAT(c ORDER BY BINARY c) FROM maria050533_xxx_croatian_ci GROUP BY c;
+GROUP_CONCAT(c ORDER BY BINARY c)
+nJ
+NJ,Nj,nj
+SELECT GROUP_CONCAT(d ORDER BY BINARY d) FROM maria050533_xxx_croatian_ci GROUP BY d;
+GROUP_CONCAT(d ORDER BY BINARY d)
+nJ
+NJ,Nj,nj
+SELECT GROUP_CONCAT(e ORDER BY BINARY e) FROM maria050533_xxx_croatian_ci GROUP BY e;
+GROUP_CONCAT(e ORDER BY BINARY e)
+nJ
+NJ,Nj,nj
+DROP TABLE maria050533_xxx_croatian_ci;
+#
+# Upgrade from Maria-10.0.4
+# Checking utf8_croatian_ci, utf8mb4_croatian_ci, ucs2_croatian_ci,
+# utf16_croatian_ci, utf32_croatian_ci
+#
+# Copying maria100004_xxx_croatian_ci.* to MYSQLD_DATADIR
+CHECK TABLE maria100004_xxx_croatian_ci FOR UPGRADE;
+Table Op Msg_type Msg_text
+test.maria100004_xxx_croatian_ci check error Table upgrade required. Please do "REPAIR TABLE `maria100004_xxx_croatian_ci`" or dump/reload to fix it!
+SELECT count(*) FROM maria100004_xxx_croatian_ci;
+ERROR HY000: Table rebuild required. Please do "ALTER TABLE `test.maria100004_xxx_croatian_ci` FORCE" or dump/reload to fix it!
+REPAIR TABLE maria100004_xxx_croatian_ci;
+Table Op Msg_type Msg_text
+test.maria100004_xxx_croatian_ci repair status OK
+SHOW CREATE TABLE maria100004_xxx_croatian_ci;
+Table Create Table
+maria100004_xxx_croatian_ci CREATE TABLE `maria100004_xxx_croatian_ci` (
+ `a` varchar(10) COLLATE utf8_croatian_ci DEFAULT NULL,
+ `b` varchar(10) CHARACTER SET utf8mb4 COLLATE utf8mb4_croatian_ci DEFAULT NULL,
+ `c` varchar(10) CHARACTER SET ucs2 COLLATE ucs2_croatian_ci DEFAULT NULL,
+ `d` varchar(10) CHARACTER SET utf16 COLLATE utf16_croatian_ci DEFAULT NULL,
+ `e` varchar(10) CHARACTER SET utf32 COLLATE utf32_croatian_ci DEFAULT NULL
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_croatian_ci
+DROP TABLE maria100004_xxx_croatian_ci;
+# Copying maria100004_xxx_croatian_ci.* to MYSQLD_DATADIR
+ALTER TABLE maria100004_xxx_croatian_ci FORCE;
+SHOW CREATE TABLE maria100004_xxx_croatian_ci;
+Table Create Table
+maria100004_xxx_croatian_ci CREATE TABLE `maria100004_xxx_croatian_ci` (
+ `a` varchar(10) COLLATE utf8_croatian_ci DEFAULT NULL,
+ `b` varchar(10) CHARACTER SET utf8mb4 COLLATE utf8mb4_croatian_ci DEFAULT NULL,
+ `c` varchar(10) CHARACTER SET ucs2 COLLATE ucs2_croatian_ci DEFAULT NULL,
+ `d` varchar(10) CHARACTER SET utf16 COLLATE utf16_croatian_ci DEFAULT NULL,
+ `e` varchar(10) CHARACTER SET utf32 COLLATE utf32_croatian_ci DEFAULT NULL
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_croatian_ci
+SELECT GROUP_CONCAT(a ORDER BY BINARY a) FROM maria100004_xxx_croatian_ci GROUP BY a;
+GROUP_CONCAT(a ORDER BY BINARY a)
+nJ
+NJ,Nj,nj
+SELECT GROUP_CONCAT(b ORDER BY BINARY b) FROM maria100004_xxx_croatian_ci GROUP BY b;
+GROUP_CONCAT(b ORDER BY BINARY b)
+nJ
+NJ,Nj,nj
+SELECT GROUP_CONCAT(c ORDER BY BINARY c) FROM maria100004_xxx_croatian_ci GROUP BY c;
+GROUP_CONCAT(c ORDER BY BINARY c)
+nJ
+NJ,Nj,nj
+SELECT GROUP_CONCAT(d ORDER BY BINARY d) FROM maria100004_xxx_croatian_ci GROUP BY d;
+GROUP_CONCAT(d ORDER BY BINARY d)
+nJ
+NJ,Nj,nj
+SELECT GROUP_CONCAT(e ORDER BY BINARY e) FROM maria100004_xxx_croatian_ci GROUP BY e;
+GROUP_CONCAT(e ORDER BY BINARY e)
+nJ
+NJ,Nj,nj
+DROP TABLE maria100004_xxx_croatian_ci;
+#
+# Upgrade from MySQL-5.6.14
+# Checking utf8_croatian_ci, utf8mb4_croatian_ci, ucs2_croatian_ci,
+# utf16_croatian_ci, utf32_croatian_ci
+#
+# Copying mysql050614_xxx_croatian_ci.* to MYSQLD_DATADIR
+CHECK TABLE mysql050614_xxx_croatian_ci FOR UPGRADE;
+Table Op Msg_type Msg_text
+test.mysql050614_xxx_croatian_ci check status OK
+SHOW CREATE TABLE mysql050614_xxx_croatian_ci;
+Table Create Table
+mysql050614_xxx_croatian_ci CREATE TABLE `mysql050614_xxx_croatian_ci` (
+ `a` varchar(10) COLLATE utf8_croatian_mysql561_ci DEFAULT NULL,
+ `b` varchar(10) CHARACTER SET utf8mb4 COLLATE utf8mb4_croatian_mysql561_ci DEFAULT NULL,
+ `c` varchar(10) CHARACTER SET ucs2 COLLATE ucs2_croatian_mysql561_ci DEFAULT NULL,
+ `d` varchar(10) CHARACTER SET utf16 COLLATE utf16_croatian_mysql561_ci DEFAULT NULL,
+ `e` varchar(10) CHARACTER SET utf32 COLLATE utf32_croatian_mysql561_ci DEFAULT NULL
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_croatian_mysql561_ci
+SELECT GROUP_CONCAT(a ORDER BY BINARY a) FROM mysql050614_xxx_croatian_ci GROUP BY a;
+GROUP_CONCAT(a ORDER BY BINARY a)
+NJ,Nj,nJ,nj
+SELECT GROUP_CONCAT(b ORDER BY BINARY b) FROM mysql050614_xxx_croatian_ci GROUP BY b;
+GROUP_CONCAT(b ORDER BY BINARY b)
+NJ,Nj,nJ,nj
+SELECT GROUP_CONCAT(c ORDER BY BINARY c) FROM mysql050614_xxx_croatian_ci GROUP BY c;
+GROUP_CONCAT(c ORDER BY BINARY c)
+NJ,Nj,nJ,nj
+SELECT GROUP_CONCAT(d ORDER BY BINARY d) FROM mysql050614_xxx_croatian_ci GROUP BY d;
+GROUP_CONCAT(d ORDER BY BINARY d)
+NJ,Nj,nJ,nj
+SELECT GROUP_CONCAT(e ORDER BY BINARY e) FROM mysql050614_xxx_croatian_ci GROUP BY e;
+GROUP_CONCAT(e ORDER BY BINARY e)
+NJ,Nj,nJ,nj
+DROP TABLE mysql050614_xxx_croatian_ci;
+#
+# Checking mysql_upgrade
+#
+# Running mysql_upgrade
+Phase 1/3: Fixing table and database names
+Phase 2/3: Checking and upgrading tables
+Processing databases
+information_schema
+mtr
+mtr.global_suppressions OK
+mtr.test_suppressions OK
+mysql
+mysql.column_stats OK
+mysql.columns_priv OK
+mysql.db OK
+mysql.event OK
+mysql.func OK
+mysql.gtid_slave_pos OK
+mysql.help_category OK
+mysql.help_keyword OK
+mysql.help_relation OK
+mysql.help_topic OK
+mysql.host OK
+mysql.index_stats OK
+mysql.innodb_index_stats OK
+mysql.innodb_table_stats OK
+mysql.plugin OK
+mysql.proc OK
+mysql.procs_priv OK
+mysql.proxies_priv OK
+mysql.roles_mapping OK
+mysql.servers OK
+mysql.table_stats OK
+mysql.tables_priv OK
+mysql.time_zone OK
+mysql.time_zone_leap_second OK
+mysql.time_zone_name OK
+mysql.time_zone_transition OK
+mysql.time_zone_transition_type OK
+mysql.user OK
+performance_schema
+test
+test.maria050313_ucs2_croatian_ci_def Needs upgrade
+test.maria050313_utf8_croatian_ci Needs upgrade
+test.maria050533_xxx_croatian_ci Needs upgrade
+test.maria100004_xxx_croatian_ci Needs upgrade
+test.mysql050614_xxx_croatian_ci OK
+
+Repairing tables
+test.maria050313_ucs2_croatian_ci_def OK
+test.maria050313_utf8_croatian_ci OK
+test.maria050533_xxx_croatian_ci OK
+test.maria100004_xxx_croatian_ci OK
+Phase 3/3: Running 'mysql_fix_privilege_tables'...
+OK
+# Running mysql_upgrade for the second time
+# This should report OK for all tables
+Phase 1/3: Fixing table and database names
+Phase 2/3: Checking and upgrading tables
+Processing databases
+information_schema
+mtr
+mtr.global_suppressions OK
+mtr.test_suppressions OK
+mysql
+mysql.column_stats OK
+mysql.columns_priv OK
+mysql.db OK
+mysql.event OK
+mysql.func OK
+mysql.gtid_slave_pos OK
+mysql.help_category OK
+mysql.help_keyword OK
+mysql.help_relation OK
+mysql.help_topic OK
+mysql.host OK
+mysql.index_stats OK
+mysql.innodb_index_stats OK
+mysql.innodb_table_stats OK
+mysql.plugin OK
+mysql.proc OK
+mysql.procs_priv OK
+mysql.proxies_priv OK
+mysql.roles_mapping OK
+mysql.servers OK
+mysql.table_stats OK
+mysql.tables_priv OK
+mysql.time_zone OK
+mysql.time_zone_leap_second OK
+mysql.time_zone_name OK
+mysql.time_zone_transition OK
+mysql.time_zone_transition_type OK
+mysql.user OK
+performance_schema
+test
+test.maria050313_ucs2_croatian_ci_def OK
+test.maria050313_utf8_croatian_ci OK
+test.maria050533_xxx_croatian_ci OK
+test.maria100004_xxx_croatian_ci OK
+test.mysql050614_xxx_croatian_ci OK
+Phase 3/3: Running 'mysql_fix_privilege_tables'...
+OK
+SHOW CREATE TABLE maria050313_ucs2_croatian_ci_def;
+Table Create Table
+maria050313_ucs2_croatian_ci_def CREATE TABLE `maria050313_ucs2_croatian_ci_def` (
+ `a` int(11) DEFAULT NULL
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_croatian_ci
+SELECT * FROM maria050313_ucs2_croatian_ci_def ORDER BY a;
+a
+1
+2
+3
+SHOW CREATE TABLE maria050313_utf8_croatian_ci;
+Table Create Table
+maria050313_utf8_croatian_ci CREATE TABLE `maria050313_utf8_croatian_ci` (
+ `a` varchar(10) CHARACTER SET utf8 COLLATE utf8_croatian_ci DEFAULT NULL
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
+SELECT GROUP_CONCAT(a ORDER BY BINARY a) FROM maria050313_utf8_croatian_ci GROUP BY a;
+GROUP_CONCAT(a ORDER BY BINARY a)
+nJ
+NJ,Nj,nj
+SHOW CREATE TABLE maria050533_xxx_croatian_ci;
+Table Create Table
+maria050533_xxx_croatian_ci CREATE TABLE `maria050533_xxx_croatian_ci` (
+ `a` varchar(10) CHARACTER SET utf8 COLLATE utf8_croatian_ci DEFAULT NULL,
+ `b` varchar(10) CHARACTER SET utf8mb4 COLLATE utf8mb4_croatian_ci DEFAULT NULL,
+ `c` varchar(10) CHARACTER SET ucs2 COLLATE ucs2_croatian_ci DEFAULT NULL,
+ `d` varchar(10) CHARACTER SET utf16 COLLATE utf16_croatian_ci DEFAULT NULL,
+ `e` varchar(10) CHARACTER SET utf32 COLLATE utf32_croatian_ci DEFAULT NULL
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
+SELECT GROUP_CONCAT(a ORDER BY BINARY a) FROM maria050533_xxx_croatian_ci GROUP BY a;
+GROUP_CONCAT(a ORDER BY BINARY a)
+nJ
+NJ,Nj,nj
+SHOW CREATE TABLE maria100004_xxx_croatian_ci;
+Table Create Table
+maria100004_xxx_croatian_ci CREATE TABLE `maria100004_xxx_croatian_ci` (
+ `a` varchar(10) COLLATE utf8_croatian_ci DEFAULT NULL,
+ `b` varchar(10) CHARACTER SET utf8mb4 COLLATE utf8mb4_croatian_ci DEFAULT NULL,
+ `c` varchar(10) CHARACTER SET ucs2 COLLATE ucs2_croatian_ci DEFAULT NULL,
+ `d` varchar(10) CHARACTER SET utf16 COLLATE utf16_croatian_ci DEFAULT NULL,
+ `e` varchar(10) CHARACTER SET utf32 COLLATE utf32_croatian_ci DEFAULT NULL
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_croatian_ci
+SELECT GROUP_CONCAT(a ORDER BY BINARY a) FROM maria100004_xxx_croatian_ci GROUP BY a;
+GROUP_CONCAT(a ORDER BY BINARY a)
+nJ
+NJ,Nj,nj
+SHOW CREATE TABLE mysql050614_xxx_croatian_ci;
+Table Create Table
+mysql050614_xxx_croatian_ci CREATE TABLE `mysql050614_xxx_croatian_ci` (
+ `a` varchar(10) COLLATE utf8_croatian_mysql561_ci DEFAULT NULL,
+ `b` varchar(10) CHARACTER SET utf8mb4 COLLATE utf8mb4_croatian_mysql561_ci DEFAULT NULL,
+ `c` varchar(10) CHARACTER SET ucs2 COLLATE ucs2_croatian_mysql561_ci DEFAULT NULL,
+ `d` varchar(10) CHARACTER SET utf16 COLLATE utf16_croatian_mysql561_ci DEFAULT NULL,
+ `e` varchar(10) CHARACTER SET utf32 COLLATE utf32_croatian_mysql561_ci DEFAULT NULL
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_croatian_mysql561_ci
+SELECT GROUP_CONCAT(a ORDER BY BINARY a) FROM mysql050614_xxx_croatian_ci GROUP BY a;
+GROUP_CONCAT(a ORDER BY BINARY a)
+NJ,Nj,nJ,nj
+DROP TABLE maria050313_ucs2_croatian_ci_def;
+DROP TABLE maria050313_utf8_croatian_ci;
+DROP TABLE maria050533_xxx_croatian_ci;
+DROP TABLE maria100004_xxx_croatian_ci;
+DROP TABLE mysql050614_xxx_croatian_ci;
diff --git a/mysql-test/r/ctype_utf16_uca.result b/mysql-test/r/ctype_utf16_uca.result
index d471f1747da..9e7cf97f8f1 100644
--- a/mysql-test/r/ctype_utf16_uca.result
+++ b/mysql-test/r/ctype_utf16_uca.result
@@ -2177,6 +2177,116 @@ ZzŹźŻżŽž
ǁ
ǂ
ǃ
+select group_concat(c1 order by binary c1 separator '') from t1 group by c1 collate utf16_croatian_mysql561_ci;
+group_concat(c1 order by binary c1 separator '')
+AaÀÁÂÃÄÅàáâãäåĀāĂ㥹ǍǎǞǟǠǡǺǻẠạẢảẤấẦầẨẩẪẫẬậẮắẰằẲẳẴẵẶặ
+AAAaaAaa
+AEAeaEae
+ÆæǢǣǼǽ
+Bb
+Ƃƃ
+CcÇçĈĉĊċ
+CHChcHch
+Čč
+Ćć
+Ƈƈ
+DdĎď
+DZDzdZdzDZDzdz
+DŽDždŽdžDŽDždž
+Đđ
+Ƌƌ
+Ðð
+EeÈÉÊËèéêëĒēĔĕĖėĘęĚěẸẹẺẻẼẽẾếỀềỂểỄễỆệ
+Ǝǝ
+Ff
+Ƒƒ
+GgĜĝĞğĠġĢģǦǧǴǵ
+Ǥǥ
+Ƣƣ
+HhĤĥ
+ƕǶ
+Ħħ
+IiÌÍÎÏìíîïĨĩĪīĬĭĮįİǏǐỈỉỊị
+IJIjiJijIJij
+JjĴĵǰ
+KkĶķǨǩ
+Ƙƙ
+LlĹĺĻļĽľ
+Ŀŀ
+LLLllLll
+LJLjlJljLJLjlj
+Łł
+Mm
+NnÑñŃńŅņŇňǸǹ
+NJNjnJnjNJNjnj
+Ŋŋ
+OoÒÓÔÕÖòóôõöŌōŎŏŐőƠơǑǒǪǫǬǭỌọỎỏỐốỒồỔổỖỗỘộỚớỜờỞởỠỡỢợ
+OEOeoEoeŒœ
+ØøǾǿ
+Pp
+Ƥƥ
+Qq
+RrŔŕŖŗŘř
+RRRrrRrr
+SsŚśŜŝŞşſ
+SSSssSssß
+Šš
+TtŢţŤť
+Ŧŧ
+Ƭƭ
+UuÙÚÛÜùúûüŨũŪūŬŭŮůŰűŲųƯưǓǔǕǖǗǘǙǚǛǜỤụỦủỨứỪừỬửỮữỰự
+Vv
+WwŴŵ
+Xx
+YyÝýÿŶŷŸ
+Ƴƴ
+ZzŹźŻż
+Žž
+Ƶƶ
+ƷǮǯ
+Ƹƹ
+Þþ
+ƿǷ
+Ƨƨ
+Ƽƽ
+Ƅƅ
select group_concat(c1 order by binary c1 separator '') from t1 group by c1 collate utf16_croatian_ci;
group_concat(c1 order by binary c1 separator '')
÷
diff --git a/mysql-test/r/ctype_utf32_uca.result b/mysql-test/r/ctype_utf32_uca.result
index cfc918f238a..ab68764a263 100644
--- a/mysql-test/r/ctype_utf32_uca.result
+++ b/mysql-test/r/ctype_utf32_uca.result
@@ -2177,6 +2177,116 @@ ZzŹźŻżŽž
ǁ
ǂ
ǃ
+select group_concat(c1 order by binary c1 separator '') from t1 group by c1 collate utf32_croatian_mysql561_ci;
+group_concat(c1 order by binary c1 separator '')
+AaÀÁÂÃÄÅàáâãäåĀāĂ㥹ǍǎǞǟǠǡǺǻẠạẢảẤấẦầẨẩẪẫẬậẮắẰằẲẳẴẵẶặ
+AAAaaAaa
+AEAeaEae
+ÆæǢǣǼǽ
+Bb
+Ƃƃ
+CcÇçĈĉĊċ
+CHChcHch
+Čč
+Ćć
+Ƈƈ
+DdĎď
+DZDzdZdzDZDzdz
+DŽDždŽdžDŽDždž
+Đđ
+Ƌƌ
+Ðð
+EeÈÉÊËèéêëĒēĔĕĖėĘęĚěẸẹẺẻẼẽẾếỀềỂểỄễỆệ
+Ǝǝ
+Ff
+Ƒƒ
+GgĜĝĞğĠġĢģǦǧǴǵ
+Ǥǥ
+Ƣƣ
+HhĤĥ
+ƕǶ
+Ħħ
+IiÌÍÎÏìíîïĨĩĪīĬĭĮįİǏǐỈỉỊị
+IJIjiJijIJij
+JjĴĵǰ
+KkĶķǨǩ
+Ƙƙ
+LlĹĺĻļĽľ
+Ŀŀ
+LLLllLll
+LJLjlJljLJLjlj
+Łł
+Mm
+NnÑñŃńŅņŇňǸǹ
+NJNjnJnjNJNjnj
+Ŋŋ
+OoÒÓÔÕÖòóôõöŌōŎŏŐőƠơǑǒǪǫǬǭỌọỎỏỐốỒồỔổỖỗỘộỚớỜờỞởỠỡỢợ
+OEOeoEoeŒœ
+ØøǾǿ
+Pp
+Ƥƥ
+Qq
+RrŔŕŖŗŘř
+RRRrrRrr
+SsŚśŜŝŞşſ
+SSSssSssß
+Šš
+TtŢţŤť
+Ŧŧ
+Ƭƭ
+UuÙÚÛÜùúûüŨũŪūŬŭŮůŰűŲųƯưǓǔǕǖǗǘǙǚǛǜỤụỦủỨứỪừỬửỮữỰự
+Vv
+WwŴŵ
+Xx
+YyÝýÿŶŷŸ
+Ƴƴ
+ZzŹźŻż
+Žž
+Ƶƶ
+ƷǮǯ
+Ƹƹ
+Þþ
+ƿǷ
+Ƨƨ
+Ƽƽ
+Ƅƅ
select group_concat(c1 order by binary c1 separator '') from t1 group by c1 collate utf32_croatian_ci;
group_concat(c1 order by binary c1 separator '')
÷
diff --git a/mysql-test/r/ctype_utf8mb4_uca.result b/mysql-test/r/ctype_utf8mb4_uca.result
index 22beb8ee4cc..1e4648eedd6 100644
--- a/mysql-test/r/ctype_utf8mb4_uca.result
+++ b/mysql-test/r/ctype_utf8mb4_uca.result
@@ -2138,6 +2138,116 @@ ZzŹźŻżŽž
ǁ
ǂ
ǃ
+SELECT GROUP_CONCAT(c1 ORDER BY c1 SEPARATOR '') FROM t1 GROUP BY c1 COLLATE utf8mb4_croatian_mysql561_ci;
+GROUP_CONCAT(c1 ORDER BY c1 SEPARATOR '')
+AaÀÁÂÃÄÅàáâãäåĀāĂ㥹ǍǎǞǟǠǡǺǻẠạẢảẤấẦầẨẩẪẫẬậẮắẰằẲẳẴẵẶặ
+AAAaaAaa
+AEAeaEae
+ÆæǢǣǼǽ
+Bb
+Ƃƃ
+CcÇçĈĉĊċ
+CHChcHch
+Čč
+Ćć
+Ƈƈ
+DdĎď
+DZDzdZdzDZDzdz
+DŽDždŽdžDŽDždž
+Đđ
+Ƌƌ
+Ðð
+EeÈÉÊËèéêëĒēĔĕĖėĘęĚěẸẹẺẻẼẽẾếỀềỂểỄễỆệ
+Ǝǝ
+Ff
+Ƒƒ
+GgĜĝĞğĠġĢģǦǧǴǵ
+Ǥǥ
+Ƣƣ
+HhĤĥ
+ƕǶ
+Ħħ
+IiÌÍÎÏìíîïĨĩĪīĬĭĮįİǏǐỈỉỊị
+IJIjiJijIJij
+JjĴĵǰ
+KkĶķǨǩ
+Ƙƙ
+LlĹĺĻļĽľ
+Ŀŀ
+LLLllLll
+LJLjlJljLJLjlj
+Łł
+Mm
+NnÑñŃńŅņŇňǸǹ
+NJNjnJnjNJNjnj
+Ŋŋ
+OoÒÓÔÕÖòóôõöŌōŎŏŐőƠơǑǒǪǫǬǭỌọỎỏỐốỒồỔổỖỗỘộỚớỜờỞởỠỡỢợ
+OEOeoEoeŒœ
+ØøǾǿ
+Pp
+Ƥƥ
+Qq
+RrŔŕŖŗŘř
+RRRrrRrr
+SsŚśŜŝŞşſ
+SSSssSssß
+Šš
+TtŢţŤť
+Ŧŧ
+Ƭƭ
+UuÙÚÛÜùúûüŨũŪūŬŭŮůŰűŲųƯưǓǔǕǖǗǘǙǚǛǜỤụỦủỨứỪừỬửỮữỰự
+Vv
+WwŴŵ
+Xx
+YyÝýÿŶŷŸ
+Ƴƴ
+ZzŹźŻż
+Žž
+Ƶƶ
+ƷǮǯ
+Ƹƹ
+Þþ
+ƿǷ
+Ƨƨ
+Ƽƽ
+Ƅƅ
SELECT GROUP_CONCAT(c1 ORDER BY c1 SEPARATOR '') FROM t1 GROUP BY c1 COLLATE utf8mb4_croatian_ci;
GROUP_CONCAT(c1 ORDER BY c1 SEPARATOR '')
÷
diff --git a/mysql-test/std_data/ctype_upgrade/maria050313_ucs2_croatian_ci_def.MYD b/mysql-test/std_data/ctype_upgrade/maria050313_ucs2_croatian_ci_def.MYD
new file mode 100644
index 00000000000..4d8505c8ef4
--- /dev/null
+++ b/mysql-test/std_data/ctype_upgrade/maria050313_ucs2_croatian_ci_def.MYD
Binary files differ
diff --git a/mysql-test/std_data/ctype_upgrade/maria050313_ucs2_croatian_ci_def.MYI b/mysql-test/std_data/ctype_upgrade/maria050313_ucs2_croatian_ci_def.MYI
new file mode 100644
index 00000000000..a8992fd55e0
--- /dev/null
+++ b/mysql-test/std_data/ctype_upgrade/maria050313_ucs2_croatian_ci_def.MYI
Binary files differ
diff --git a/mysql-test/std_data/ctype_upgrade/maria050313_ucs2_croatian_ci_def.frm b/mysql-test/std_data/ctype_upgrade/maria050313_ucs2_croatian_ci_def.frm
new file mode 100644
index 00000000000..936f485f80e
--- /dev/null
+++ b/mysql-test/std_data/ctype_upgrade/maria050313_ucs2_croatian_ci_def.frm
Binary files differ
diff --git a/mysql-test/std_data/ctype_upgrade/maria050313_utf8_croatian_ci.MYD b/mysql-test/std_data/ctype_upgrade/maria050313_utf8_croatian_ci.MYD
new file mode 100644
index 00000000000..1a6557647d1
--- /dev/null
+++ b/mysql-test/std_data/ctype_upgrade/maria050313_utf8_croatian_ci.MYD
Binary files differ
diff --git a/mysql-test/std_data/ctype_upgrade/maria050313_utf8_croatian_ci.MYI b/mysql-test/std_data/ctype_upgrade/maria050313_utf8_croatian_ci.MYI
new file mode 100644
index 00000000000..b55b64612dd
--- /dev/null
+++ b/mysql-test/std_data/ctype_upgrade/maria050313_utf8_croatian_ci.MYI
Binary files differ
diff --git a/mysql-test/std_data/ctype_upgrade/maria050313_utf8_croatian_ci.frm b/mysql-test/std_data/ctype_upgrade/maria050313_utf8_croatian_ci.frm
new file mode 100644
index 00000000000..22645fbec0d
--- /dev/null
+++ b/mysql-test/std_data/ctype_upgrade/maria050313_utf8_croatian_ci.frm
Binary files differ
diff --git a/mysql-test/std_data/ctype_upgrade/maria050533_xxx_croatian_ci.MYD b/mysql-test/std_data/ctype_upgrade/maria050533_xxx_croatian_ci.MYD
new file mode 100644
index 00000000000..4b9377d704c
--- /dev/null
+++ b/mysql-test/std_data/ctype_upgrade/maria050533_xxx_croatian_ci.MYD
Binary files differ
diff --git a/mysql-test/std_data/ctype_upgrade/maria050533_xxx_croatian_ci.MYI b/mysql-test/std_data/ctype_upgrade/maria050533_xxx_croatian_ci.MYI
new file mode 100644
index 00000000000..7d349ed7bb3
--- /dev/null
+++ b/mysql-test/std_data/ctype_upgrade/maria050533_xxx_croatian_ci.MYI
Binary files differ
diff --git a/mysql-test/std_data/ctype_upgrade/maria050533_xxx_croatian_ci.frm b/mysql-test/std_data/ctype_upgrade/maria050533_xxx_croatian_ci.frm
new file mode 100644
index 00000000000..759d57f3088
--- /dev/null
+++ b/mysql-test/std_data/ctype_upgrade/maria050533_xxx_croatian_ci.frm
Binary files differ
diff --git a/mysql-test/std_data/ctype_upgrade/maria100004_xxx_croatian_ci.MYD b/mysql-test/std_data/ctype_upgrade/maria100004_xxx_croatian_ci.MYD
new file mode 100644
index 00000000000..4b9377d704c
--- /dev/null
+++ b/mysql-test/std_data/ctype_upgrade/maria100004_xxx_croatian_ci.MYD
Binary files differ
diff --git a/mysql-test/std_data/ctype_upgrade/maria100004_xxx_croatian_ci.MYI b/mysql-test/std_data/ctype_upgrade/maria100004_xxx_croatian_ci.MYI
new file mode 100644
index 00000000000..15336f19ec9
--- /dev/null
+++ b/mysql-test/std_data/ctype_upgrade/maria100004_xxx_croatian_ci.MYI
Binary files differ
diff --git a/mysql-test/std_data/ctype_upgrade/maria100004_xxx_croatian_ci.frm b/mysql-test/std_data/ctype_upgrade/maria100004_xxx_croatian_ci.frm
new file mode 100644
index 00000000000..adb520df85c
--- /dev/null
+++ b/mysql-test/std_data/ctype_upgrade/maria100004_xxx_croatian_ci.frm
Binary files differ
diff --git a/mysql-test/std_data/ctype_upgrade/mysql050614_xxx_croatian_ci.MYD b/mysql-test/std_data/ctype_upgrade/mysql050614_xxx_croatian_ci.MYD
new file mode 100644
index 00000000000..4b9377d704c
--- /dev/null
+++ b/mysql-test/std_data/ctype_upgrade/mysql050614_xxx_croatian_ci.MYD
Binary files differ
diff --git a/mysql-test/std_data/ctype_upgrade/mysql050614_xxx_croatian_ci.MYI b/mysql-test/std_data/ctype_upgrade/mysql050614_xxx_croatian_ci.MYI
new file mode 100644
index 00000000000..de1ec112abb
--- /dev/null
+++ b/mysql-test/std_data/ctype_upgrade/mysql050614_xxx_croatian_ci.MYI
Binary files differ
diff --git a/mysql-test/std_data/ctype_upgrade/mysql050614_xxx_croatian_ci.frm b/mysql-test/std_data/ctype_upgrade/mysql050614_xxx_croatian_ci.frm
new file mode 100644
index 00000000000..d26ba4f7e85
--- /dev/null
+++ b/mysql-test/std_data/ctype_upgrade/mysql050614_xxx_croatian_ci.frm
Binary files differ
diff --git a/mysql-test/suite/engines/funcs/r/db_alter_collate_ascii.result b/mysql-test/suite/engines/funcs/r/db_alter_collate_ascii.result
index 231954975ad..5345ead7b20 100644
--- a/mysql-test/suite/engines/funcs/r/db_alter_collate_ascii.result
+++ b/mysql-test/suite/engines/funcs/r/db_alter_collate_ascii.result
@@ -78,8 +78,9 @@ utf8_esperanto_ci utf8 209 # #
utf8_hungarian_ci utf8 210 # #
utf8_sinhala_ci utf8 211 # #
utf8_german2_ci utf8 212 # #
-utf8_croatian_ci utf8 213 # #
+utf8_croatian_mysql561_ci utf8 213 # #
utf8_general_mysql500_ci utf8 223 # #
+utf8_croatian_ci utf8 576 # #
ucs2_general_ci ucs2 35 Yes # #
ucs2_bin ucs2 90 # #
ucs2_unicode_ci ucs2 128 # #
@@ -103,8 +104,9 @@ ucs2_esperanto_ci ucs2 145 # #
ucs2_hungarian_ci ucs2 146 # #
ucs2_sinhala_ci ucs2 147 # #
ucs2_german2_ci ucs2 148 # #
-ucs2_croatian_ci ucs2 149 # #
+ucs2_croatian_mysql561_ci ucs2 149 # #
ucs2_general_mysql500_ci ucs2 159 # #
+ucs2_croatian_ci ucs2 640 # #
cp866_general_ci cp866 36 Yes # #
cp866_bin cp866 68 # #
keybcs2_general_ci keybcs2 37 Yes # #
@@ -142,7 +144,8 @@ utf8mb4_esperanto_ci utf8mb4 241 # #
utf8mb4_hungarian_ci utf8mb4 242 # #
utf8mb4_sinhala_ci utf8mb4 243 # #
utf8mb4_german2_ci utf8mb4 244 # #
-utf8mb4_croatian_ci utf8mb4 245 # #
+utf8mb4_croatian_mysql561_ci utf8mb4 245 # #
+utf8mb4_croatian_ci utf8mb4 608 # #
cp1251_bulgarian_ci cp1251 14 # #
cp1251_ukrainian_ci cp1251 23 # #
cp1251_bin cp1251 50 # #
@@ -171,7 +174,8 @@ utf16_esperanto_ci utf16 118 # #
utf16_hungarian_ci utf16 119 # #
utf16_sinhala_ci utf16 120 # #
utf16_german2_ci utf16 121 # #
-utf16_croatian_ci utf16 215 # #
+utf16_croatian_mysql561_ci utf16 122 # #
+utf16_croatian_ci utf16 672 # #
utf16le_general_ci utf16le 56 Yes # #
utf16le_bin utf16le 62 # #
cp1256_general_ci cp1256 57 Yes # #
@@ -202,7 +206,8 @@ utf32_esperanto_ci utf32 177 # #
utf32_hungarian_ci utf32 178 # #
utf32_sinhala_ci utf32 179 # #
utf32_german2_ci utf32 180 # #
-utf32_croatian_ci utf32 214 # #
+utf32_croatian_mysql561_ci utf32 181 # #
+utf32_croatian_ci utf32 736 # #
binary binary 63 Yes # #
geostd8_general_ci geostd8 92 Yes # #
geostd8_bin geostd8 93 # #
diff --git a/mysql-test/suite/engines/funcs/r/db_alter_collate_utf8.result b/mysql-test/suite/engines/funcs/r/db_alter_collate_utf8.result
index 4ca2aa14117..51ae9004b43 100644
--- a/mysql-test/suite/engines/funcs/r/db_alter_collate_utf8.result
+++ b/mysql-test/suite/engines/funcs/r/db_alter_collate_utf8.result
@@ -78,8 +78,9 @@ utf8_esperanto_ci utf8 209 # #
utf8_hungarian_ci utf8 210 # #
utf8_sinhala_ci utf8 211 # #
utf8_german2_ci utf8 212 # #
-utf8_croatian_ci utf8 213 # #
+utf8_croatian_mysql561_ci utf8 213 # #
utf8_general_mysql500_ci utf8 223 # #
+utf8_croatian_ci utf8 576 # #
ucs2_general_ci ucs2 35 Yes # #
ucs2_bin ucs2 90 # #
ucs2_unicode_ci ucs2 128 # #
@@ -103,8 +104,9 @@ ucs2_esperanto_ci ucs2 145 # #
ucs2_hungarian_ci ucs2 146 # #
ucs2_sinhala_ci ucs2 147 # #
ucs2_german2_ci ucs2 148 # #
-ucs2_croatian_ci ucs2 149 # #
+ucs2_croatian_mysql561_ci ucs2 149 # #
ucs2_general_mysql500_ci ucs2 159 # #
+ucs2_croatian_ci ucs2 640 # #
cp866_general_ci cp866 36 Yes # #
cp866_bin cp866 68 # #
keybcs2_general_ci keybcs2 37 Yes # #
@@ -142,7 +144,8 @@ utf8mb4_esperanto_ci utf8mb4 241 # #
utf8mb4_hungarian_ci utf8mb4 242 # #
utf8mb4_sinhala_ci utf8mb4 243 # #
utf8mb4_german2_ci utf8mb4 244 # #
-utf8mb4_croatian_ci utf8mb4 245 # #
+utf8mb4_croatian_mysql561_ci utf8mb4 245 # #
+utf8mb4_croatian_ci utf8mb4 608 # #
cp1251_bulgarian_ci cp1251 14 # #
cp1251_ukrainian_ci cp1251 23 # #
cp1251_bin cp1251 50 # #
@@ -171,7 +174,8 @@ utf16_esperanto_ci utf16 118 # #
utf16_hungarian_ci utf16 119 # #
utf16_sinhala_ci utf16 120 # #
utf16_german2_ci utf16 121 # #
-utf16_croatian_ci utf16 215 # #
+utf16_croatian_mysql561_ci utf16 122 # #
+utf16_croatian_ci utf16 672 # #
utf16le_general_ci utf16le 56 Yes # #
utf16le_bin utf16le 62 # #
cp1256_general_ci cp1256 57 Yes # #
@@ -202,7 +206,8 @@ utf32_esperanto_ci utf32 177 # #
utf32_hungarian_ci utf32 178 # #
utf32_sinhala_ci utf32 179 # #
utf32_german2_ci utf32 180 # #
-utf32_croatian_ci utf32 214 # #
+utf32_croatian_mysql561_ci utf32 181 # #
+utf32_croatian_ci utf32 736 # #
binary binary 63 Yes # #
geostd8_general_ci geostd8 92 Yes # #
geostd8_bin geostd8 93 # #
diff --git a/mysql-test/suite/innodb/r/innodb_ctype_ldml.result b/mysql-test/suite/innodb/r/innodb_ctype_ldml.result
index 8da04d8828b..0008de141dc 100644
--- a/mysql-test/suite/innodb/r/innodb_ctype_ldml.result
+++ b/mysql-test/suite/innodb/r/innodb_ctype_ldml.result
@@ -388,7 +388,7 @@ select "foo" = "foo " collate latin1_test;
"foo" = "foo " collate latin1_test
1
The following tests check that two-byte collation IDs work
-select * from information_schema.collations where id>256 order by id;
+select * from information_schema.collations where id>256 and is_compiled<>'Yes' order by id;
COLLATION_NAME CHARACTER_SET_NAME ID IS_DEFAULT IS_COMPILED SORTLEN
utf8mb4_test_ci utf8mb4 326 8
utf16_test_ci utf16 327 8
diff --git a/mysql-test/suite/innodb/t/innodb_ctype_ldml.test b/mysql-test/suite/innodb/t/innodb_ctype_ldml.test
index ddc3bac36c7..011271e4e22 100644
--- a/mysql-test/suite/innodb/t/innodb_ctype_ldml.test
+++ b/mysql-test/suite/innodb/t/innodb_ctype_ldml.test
@@ -170,7 +170,7 @@ select "foo" = "foo " collate latin1_test;
# The file ../std-data/Index.xml has a number of collations with high IDs.
# Test that the "ID" column in I_S and SHOW queries can handle two bytes
-select * from information_schema.collations where id>256 order by id;
+select * from information_schema.collations where id>256 and is_compiled<>'Yes' order by id;
show collation like '%test%';
# Test that two-byte collation ID is correctly transfered to the client side.
diff --git a/mysql-test/suite/plugins/r/show_all_plugins.result b/mysql-test/suite/plugins/r/show_all_plugins.result
index fb31a49ab89..72ad829727c 100644
--- a/mysql-test/suite/plugins/r/show_all_plugins.result
+++ b/mysql-test/suite/plugins/r/show_all_plugins.result
@@ -4,8 +4,8 @@ Variable_name Value
Opened_plugin_libraries 0
select * from information_schema.all_plugins where plugin_library='ha_example.so';
PLUGIN_NAME PLUGIN_VERSION PLUGIN_STATUS PLUGIN_TYPE PLUGIN_TYPE_VERSION PLUGIN_LIBRARY PLUGIN_LIBRARY_VERSION PLUGIN_AUTHOR PLUGIN_DESCRIPTION PLUGIN_LICENSE LOAD_OPTION PLUGIN_MATURITY PLUGIN_AUTH_VERSION
-EXAMPLE 0.1 NOT INSTALLED STORAGE ENGINE 100004.0 ha_example.so 1.7 Brian Aker, MySQL AB Example storage engine GPL OFF Experimental 0.1
-UNUSABLE 3.14 NOT INSTALLED DAEMON 100004.0 ha_example.so 1.7 Sergei Golubchik Unusable Daemon GPL OFF Experimental 3.14.15.926
+EXAMPLE 0.1 NOT INSTALLED STORAGE ENGINE 100006.0 ha_example.so 1.7 Brian Aker, MySQL AB Example storage engine GPL OFF Experimental 0.1
+UNUSABLE 3.14 NOT INSTALLED DAEMON 100006.0 ha_example.so 1.7 Sergei Golubchik Unusable Daemon GPL OFF Experimental 3.14.15.926
show status like '%libraries%';
Variable_name Value
Opened_plugin_libraries 1
diff --git a/mysql-test/suite/roles/create_and_drop_role_invalid_user_table.result b/mysql-test/suite/roles/create_and_drop_role_invalid_user_table.result
index d0254fc2c44..7946f32663f 100644
--- a/mysql-test/suite/roles/create_and_drop_role_invalid_user_table.result
+++ b/mysql-test/suite/roles/create_and_drop_role_invalid_user_table.result
@@ -2,7 +2,7 @@ use mysql;
alter table user drop column is_role;
flush privileges;
create role test_role;
-ERROR HY000: Column count of mysql.user is wrong. Expected 44, found 43. Created with MariaDB 100004, now running 100004. Please use mysql_upgrade to fix this error.
+ERROR HY000: Column count of mysql.user is wrong. Expected 44, found 43. Created with MariaDB 100006, now running 100006. Please use mysql_upgrade to fix this error.
drop role test_role;
ERROR HY000: Operation DROP ROLE failed for 'test_role'
alter table user add column is_role enum('N', 'Y') default 'N' not null
diff --git a/mysql-test/t/ctype_ldml.test b/mysql-test/t/ctype_ldml.test
index 82dfd1c8591..11ef73e3360 100644
--- a/mysql-test/t/ctype_ldml.test
+++ b/mysql-test/t/ctype_ldml.test
@@ -152,7 +152,7 @@ select "foo" = "foo " collate latin1_test;
# The file ../std-data/Index.xml has a number of collations with high IDs.
# Test that the "ID" column in I_S and SHOW queries can handle two bytes
-select * from information_schema.collations where id>256 order by id;
+select * from information_schema.collations where id>256 and is_compiled<>'Yes' order by id;
show collation like '%test%';
# Test that two-byte collation ID is correctly transfered to the client side.
diff --git a/mysql-test/t/ctype_uca.test b/mysql-test/t/ctype_uca.test
index 16ec673de34..ca03f57952e 100644
--- a/mysql-test/t/ctype_uca.test
+++ b/mysql-test/t/ctype_uca.test
@@ -65,6 +65,7 @@ select group_concat(c1 order by c1) from t1 group by c1 collate utf8_spanish2_ci
select group_concat(c1 order by c1) from t1 group by c1 collate utf8_roman_ci;
select group_concat(c1 order by c1) from t1 group by c1 collate utf8_esperanto_ci;
select group_concat(c1 order by c1) from t1 group by c1 collate utf8_hungarian_ci;
+select group_concat(c1 order by c1) from t1 group by c1 collate utf8_croatian_mysql561_ci;
select group_concat(c1 order by c1) from t1 group by c1 collate utf8_croatian_ci;
select group_concat(c1 order by c1) from t1 group by c1 collate utf8_german2_ci;
@@ -87,6 +88,7 @@ SELECT GROUP_CONCAT(c1 ORDER BY c1) FROM t1 GROUP BY c1 COLLATE ucs2_spanish2_ci
SELECT GROUP_CONCAT(c1 ORDER BY c1) FROM t1 GROUP BY c1 COLLATE ucs2_roman_ci;
SELECT GROUP_CONCAT(c1 ORDER BY c1) FROM t1 GROUP BY c1 COLLATE ucs2_esperanto_ci;
SELECT GROUP_CONCAT(c1 ORDER BY c1) FROM t1 GROUP BY c1 COLLATE ucs2_hungarian_ci;
+SELECT GROUP_CONCAT(c1 ORDER BY c1) FROM t1 GROUP BY c1 COLLATE ucs2_croatian_mysql561_ci;
SELECT GROUP_CONCAT(c1 ORDER BY c1) FROM t1 GROUP BY c1 COLLATE ucs2_croatian_ci;
SELECT GROUP_CONCAT(c1 ORDER BY c1) FROM t1 GROUP BY c1 COLLATE ucs2_german2_ci;
@@ -485,7 +487,7 @@ SET collation_connection=ucs2_czech_ci;
--source include/ctype_czech.inc
--source include/ctype_like_ignorable.inc
-create table t1 (a int, c1 varchar(200) collate utf8_croatian_ci, key (c1));
+create table t1 (a int, c1 varchar(200) collate utf8_croatian_mysql561_ci, key (c1));
insert into t1 values (1,'=> DZ'),(2,'=> Dz'),(3,'=> dz'),(4,'=> dZ');
insert into t1 values (5,'=> DŽ'),(6,'=> Dž'),(7,'=> dž'),(8,'=> dŽ');
insert into t1 values (9,'=> dž'),(10,'=> DŽ');
diff --git a/mysql-test/t/ctype_upgrade.test b/mysql-test/t/ctype_upgrade.test
new file mode 100644
index 00000000000..cc59d1e4401
--- /dev/null
+++ b/mysql-test/t/ctype_upgrade.test
@@ -0,0 +1,198 @@
+-- source include/mysql_upgrade_preparation.inc
+-- source include/have_innodb.inc
+
+call mtr.add_suppression("Table rebuild required");
+let $MYSQLD_DATADIR= `select @@datadir`;
+
+--echo #
+--echo # Upgrade from Maria-5.3.13:
+--echo # Checking utf8_croatian_ci in a VARCHAR column
+--echo #
+
+--echo # Copying maria050313_utf8_croatian_ci.* to MYSQLD_DATADIR
+--copy_file std_data/ctype_upgrade/maria050313_utf8_croatian_ci.frm $MYSQLD_DATADIR/test/maria050313_utf8_croatian_ci.frm
+--copy_file std_data/ctype_upgrade/maria050313_utf8_croatian_ci.MYD $MYSQLD_DATADIR/test/maria050313_utf8_croatian_ci.MYD
+--copy_file std_data/ctype_upgrade/maria050313_utf8_croatian_ci.MYI $MYSQLD_DATADIR/test/maria050313_utf8_croatian_ci.MYI
+# Following test should show that table is corrupted
+CHECK TABLE maria050313_utf8_croatian_ci FOR UPGRADE;
+--error ER_TABLE_NEEDS_REBUILD
+SHOW CREATE TABLE maria050313_utf8_croatian_ci;
+# Check that REPAIR fixes the table
+REPAIR TABLE maria050313_utf8_croatian_ci;
+CHECK TABLE maria050313_utf8_croatian_ci FOR UPGRADE;
+SHOW CREATE TABLE maria050313_utf8_croatian_ci;
+SELECT count(*) FROM maria050313_utf8_croatian_ci;
+DROP TABLE maria050313_utf8_croatian_ci;
+
+--echo # Copying maria050313_utf8_croatian_ci.* to MYSQLD_DATADIR
+--copy_file std_data/ctype_upgrade/maria050313_utf8_croatian_ci.frm $MYSQLD_DATADIR/test/maria050313_utf8_croatian_ci.frm
+--copy_file std_data/ctype_upgrade/maria050313_utf8_croatian_ci.MYD $MYSQLD_DATADIR/test/maria050313_utf8_croatian_ci.MYD
+--copy_file std_data/ctype_upgrade/maria050313_utf8_croatian_ci.MYI $MYSQLD_DATADIR/test/maria050313_utf8_croatian_ci.MYI
+ALTER TABLE maria050313_utf8_croatian_ci FORCE;
+SHOW CREATE TABLE maria050313_utf8_croatian_ci;
+SELECT GROUP_CONCAT(a ORDER BY BINARY a) FROM maria050313_utf8_croatian_ci GROUP BY a;
+DROP TABLE maria050313_utf8_croatian_ci;
+
+
+--echo #
+--echo # Upgrade from Maria-5.3.13:
+--echo # Checking ucs2_croatian_ci in the table default collation
+--echo #
+
+--echo # Copying maria050313_ucs2_croatian_ci.* to MYSQLD_DATADIR
+--copy_file std_data/ctype_upgrade/maria050313_ucs2_croatian_ci_def.frm $MYSQLD_DATADIR/test/maria050313_ucs2_croatian_ci_def.frm
+--copy_file std_data/ctype_upgrade/maria050313_ucs2_croatian_ci_def.MYD $MYSQLD_DATADIR/test/maria050313_ucs2_croatian_ci_def.MYD
+--copy_file std_data/ctype_upgrade/maria050313_ucs2_croatian_ci_def.MYI $MYSQLD_DATADIR/test/maria050313_ucs2_croatian_ci_def.MYI
+CHECK TABLE maria050313_ucs2_croatian_ci_def FOR UPGRADE;
+--error ER_TABLE_NEEDS_REBUILD
+SELECT count(*) FROM maria050313_ucs2_croatian_ci_def;
+REPAIR TABLE maria050313_ucs2_croatian_ci_def;
+SHOW CREATE TABLE maria050313_ucs2_croatian_ci_def;
+DROP TABLE maria050313_ucs2_croatian_ci_def;
+
+--echo # Copying maria050313_ucs2_croatian_ci.* to MYSQLD_DATADIR
+--copy_file std_data/ctype_upgrade/maria050313_ucs2_croatian_ci_def.frm $MYSQLD_DATADIR/test/maria050313_ucs2_croatian_ci_def.frm
+--copy_file std_data/ctype_upgrade/maria050313_ucs2_croatian_ci_def.MYD $MYSQLD_DATADIR/test/maria050313_ucs2_croatian_ci_def.MYD
+--copy_file std_data/ctype_upgrade/maria050313_ucs2_croatian_ci_def.MYI $MYSQLD_DATADIR/test/maria050313_ucs2_croatian_ci_def.MYI
+CHECK TABLE maria050313_ucs2_croatian_ci_def;
+REPAIR TABLE maria050313_ucs2_croatian_ci_def;
+CHECK TABLE maria050313_ucs2_croatian_ci_def;
+SHOW CREATE TABLE maria050313_ucs2_croatian_ci_def;
+SELECT * FROM maria050313_ucs2_croatian_ci_def ORDER BY a;
+DROP TABLE maria050313_ucs2_croatian_ci_def;
+
+
+
+--echo #
+--echo # Upgrade from Maria-5.5.33
+--echo # Checking utf8_croatian_ci, utf8mb4_croatian_ci, ucs2_croatian_ci,
+--echo # utf16_croatian_ci, utf32_croatian_ci
+--echo #
+
+--echo # Copying maria050533_xxx_croatian_ci.* to MYSQLD_DATADIR
+--copy_file std_data/ctype_upgrade/maria050533_xxx_croatian_ci.frm $MYSQLD_DATADIR/test/maria050533_xxx_croatian_ci.frm
+--copy_file std_data/ctype_upgrade/maria050533_xxx_croatian_ci.MYD $MYSQLD_DATADIR/test/maria050533_xxx_croatian_ci.MYD
+--copy_file std_data/ctype_upgrade/maria050533_xxx_croatian_ci.MYI $MYSQLD_DATADIR/test/maria050533_xxx_croatian_ci.MYI
+CHECK TABLE maria050533_xxx_croatian_ci FOR UPGRADE;
+REPAIR TABLE maria050533_xxx_croatian_ci;
+SHOW CREATE TABLE maria050533_xxx_croatian_ci;
+SELECT count(*) FROM maria050533_xxx_croatian_ci;
+DROP TABLE maria050533_xxx_croatian_ci;
+
+--echo # Copying maria050533_xxx_croatian_ci.* to MYSQLD_DATADIR
+--copy_file std_data/ctype_upgrade/maria050533_xxx_croatian_ci.frm $MYSQLD_DATADIR/test/maria050533_xxx_croatian_ci.frm
+--copy_file std_data/ctype_upgrade/maria050533_xxx_croatian_ci.MYD $MYSQLD_DATADIR/test/maria050533_xxx_croatian_ci.MYD
+--copy_file std_data/ctype_upgrade/maria050533_xxx_croatian_ci.MYI $MYSQLD_DATADIR/test/maria050533_xxx_croatian_ci.MYI
+ALTER TABLE maria050533_xxx_croatian_ci FORCE;
+SHOW CREATE TABLE maria050533_xxx_croatian_ci;
+SELECT GROUP_CONCAT(a ORDER BY BINARY a) FROM maria050533_xxx_croatian_ci GROUP BY a;
+SELECT GROUP_CONCAT(b ORDER BY BINARY b) FROM maria050533_xxx_croatian_ci GROUP BY b;
+SELECT GROUP_CONCAT(c ORDER BY BINARY c) FROM maria050533_xxx_croatian_ci GROUP BY c;
+SELECT GROUP_CONCAT(d ORDER BY BINARY d) FROM maria050533_xxx_croatian_ci GROUP BY d;
+SELECT GROUP_CONCAT(e ORDER BY BINARY e) FROM maria050533_xxx_croatian_ci GROUP BY e;
+DROP TABLE maria050533_xxx_croatian_ci;
+
+
+--echo #
+--echo # Upgrade from Maria-10.0.4
+--echo # Checking utf8_croatian_ci, utf8mb4_croatian_ci, ucs2_croatian_ci,
+--echo # utf16_croatian_ci, utf32_croatian_ci
+--echo #
+
+--echo # Copying maria100004_xxx_croatian_ci.* to MYSQLD_DATADIR
+--copy_file std_data/ctype_upgrade/maria100004_xxx_croatian_ci.frm $MYSQLD_DATADIR/test/maria100004_xxx_croatian_ci.frm
+--copy_file std_data/ctype_upgrade/maria100004_xxx_croatian_ci.MYD $MYSQLD_DATADIR/test/maria100004_xxx_croatian_ci.MYD
+--copy_file std_data/ctype_upgrade/maria100004_xxx_croatian_ci.MYI $MYSQLD_DATADIR/test/maria100004_xxx_croatian_ci.MYI
+CHECK TABLE maria100004_xxx_croatian_ci FOR UPGRADE;
+--error ER_TABLE_NEEDS_REBUILD
+SELECT count(*) FROM maria100004_xxx_croatian_ci;
+REPAIR TABLE maria100004_xxx_croatian_ci;
+SHOW CREATE TABLE maria100004_xxx_croatian_ci;
+DROP TABLE maria100004_xxx_croatian_ci;
+
+--echo # Copying maria100004_xxx_croatian_ci.* to MYSQLD_DATADIR
+--copy_file std_data/ctype_upgrade/maria100004_xxx_croatian_ci.frm $MYSQLD_DATADIR/test/maria100004_xxx_croatian_ci.frm
+--copy_file std_data/ctype_upgrade/maria100004_xxx_croatian_ci.MYD $MYSQLD_DATADIR/test/maria100004_xxx_croatian_ci.MYD
+--copy_file std_data/ctype_upgrade/maria100004_xxx_croatian_ci.MYI $MYSQLD_DATADIR/test/maria100004_xxx_croatian_ci.MYI
+ALTER TABLE maria100004_xxx_croatian_ci FORCE;
+SHOW CREATE TABLE maria100004_xxx_croatian_ci;
+SELECT GROUP_CONCAT(a ORDER BY BINARY a) FROM maria100004_xxx_croatian_ci GROUP BY a;
+SELECT GROUP_CONCAT(b ORDER BY BINARY b) FROM maria100004_xxx_croatian_ci GROUP BY b;
+SELECT GROUP_CONCAT(c ORDER BY BINARY c) FROM maria100004_xxx_croatian_ci GROUP BY c;
+SELECT GROUP_CONCAT(d ORDER BY BINARY d) FROM maria100004_xxx_croatian_ci GROUP BY d;
+SELECT GROUP_CONCAT(e ORDER BY BINARY e) FROM maria100004_xxx_croatian_ci GROUP BY e;
+DROP TABLE maria100004_xxx_croatian_ci;
+
+
+
+--echo #
+--echo # Upgrade from MySQL-5.6.14
+--echo # Checking utf8_croatian_ci, utf8mb4_croatian_ci, ucs2_croatian_ci,
+--echo # utf16_croatian_ci, utf32_croatian_ci
+--echo #
+
+--echo # Copying mysql050614_xxx_croatian_ci.* to MYSQLD_DATADIR
+--copy_file std_data/ctype_upgrade/mysql050614_xxx_croatian_ci.frm $MYSQLD_DATADIR/test/mysql050614_xxx_croatian_ci.frm
+--copy_file std_data/ctype_upgrade/mysql050614_xxx_croatian_ci.MYD $MYSQLD_DATADIR/test/mysql050614_xxx_croatian_ci.MYD
+--copy_file std_data/ctype_upgrade/mysql050614_xxx_croatian_ci.MYI $MYSQLD_DATADIR/test/mysql050614_xxx_croatian_ci.MYI
+CHECK TABLE mysql050614_xxx_croatian_ci FOR UPGRADE;
+SHOW CREATE TABLE mysql050614_xxx_croatian_ci;
+SELECT GROUP_CONCAT(a ORDER BY BINARY a) FROM mysql050614_xxx_croatian_ci GROUP BY a;
+SELECT GROUP_CONCAT(b ORDER BY BINARY b) FROM mysql050614_xxx_croatian_ci GROUP BY b;
+SELECT GROUP_CONCAT(c ORDER BY BINARY c) FROM mysql050614_xxx_croatian_ci GROUP BY c;
+SELECT GROUP_CONCAT(d ORDER BY BINARY d) FROM mysql050614_xxx_croatian_ci GROUP BY d;
+SELECT GROUP_CONCAT(e ORDER BY BINARY e) FROM mysql050614_xxx_croatian_ci GROUP BY e;
+DROP TABLE mysql050614_xxx_croatian_ci;
+
+
+--echo #
+--echo # Checking mysql_upgrade
+--echo #
+--copy_file std_data/ctype_upgrade/maria050313_utf8_croatian_ci.frm $MYSQLD_DATADIR/test/maria050313_utf8_croatian_ci.frm
+--copy_file std_data/ctype_upgrade/maria050313_utf8_croatian_ci.MYD $MYSQLD_DATADIR/test/maria050313_utf8_croatian_ci.MYD
+--copy_file std_data/ctype_upgrade/maria050313_utf8_croatian_ci.MYI $MYSQLD_DATADIR/test/maria050313_utf8_croatian_ci.MYI
+
+--copy_file std_data/ctype_upgrade/maria050313_ucs2_croatian_ci_def.frm $MYSQLD_DATADIR/test/maria050313_ucs2_croatian_ci_def.frm
+--copy_file std_data/ctype_upgrade/maria050313_ucs2_croatian_ci_def.MYD $MYSQLD_DATADIR/test/maria050313_ucs2_croatian_ci_def.MYD
+--copy_file std_data/ctype_upgrade/maria050313_ucs2_croatian_ci_def.MYI $MYSQLD_DATADIR/test/maria050313_ucs2_croatian_ci_def.MYI
+
+--copy_file std_data/ctype_upgrade/maria050533_xxx_croatian_ci.frm $MYSQLD_DATADIR/test/maria050533_xxx_croatian_ci.frm
+--copy_file std_data/ctype_upgrade/maria050533_xxx_croatian_ci.MYD $MYSQLD_DATADIR/test/maria050533_xxx_croatian_ci.MYD
+--copy_file std_data/ctype_upgrade/maria050533_xxx_croatian_ci.MYI $MYSQLD_DATADIR/test/maria050533_xxx_croatian_ci.MYI
+
+--copy_file std_data/ctype_upgrade/maria100004_xxx_croatian_ci.frm $MYSQLD_DATADIR/test/maria100004_xxx_croatian_ci.frm
+--copy_file std_data/ctype_upgrade/maria100004_xxx_croatian_ci.MYD $MYSQLD_DATADIR/test/maria100004_xxx_croatian_ci.MYD
+--copy_file std_data/ctype_upgrade/maria100004_xxx_croatian_ci.MYI $MYSQLD_DATADIR/test/maria100004_xxx_croatian_ci.MYI
+
+--copy_file std_data/ctype_upgrade/mysql050614_xxx_croatian_ci.frm $MYSQLD_DATADIR/test/mysql050614_xxx_croatian_ci.frm
+--copy_file std_data/ctype_upgrade/mysql050614_xxx_croatian_ci.MYD $MYSQLD_DATADIR/test/mysql050614_xxx_croatian_ci.MYD
+--copy_file std_data/ctype_upgrade/mysql050614_xxx_croatian_ci.MYI $MYSQLD_DATADIR/test/mysql050614_xxx_croatian_ci.MYI
+
+--echo # Running mysql_upgrade
+--exec $MYSQL_UPGRADE 2>&1
+
+
+--echo # Running mysql_upgrade for the second time
+--echo # This should report OK for all tables
+--exec $MYSQL_UPGRADE --force 2>&1
+
+SHOW CREATE TABLE maria050313_ucs2_croatian_ci_def;
+SELECT * FROM maria050313_ucs2_croatian_ci_def ORDER BY a;
+
+SHOW CREATE TABLE maria050313_utf8_croatian_ci;
+SELECT GROUP_CONCAT(a ORDER BY BINARY a) FROM maria050313_utf8_croatian_ci GROUP BY a;
+
+SHOW CREATE TABLE maria050533_xxx_croatian_ci;
+SELECT GROUP_CONCAT(a ORDER BY BINARY a) FROM maria050533_xxx_croatian_ci GROUP BY a;
+
+SHOW CREATE TABLE maria100004_xxx_croatian_ci;
+SELECT GROUP_CONCAT(a ORDER BY BINARY a) FROM maria100004_xxx_croatian_ci GROUP BY a;
+
+SHOW CREATE TABLE mysql050614_xxx_croatian_ci;
+SELECT GROUP_CONCAT(a ORDER BY BINARY a) FROM mysql050614_xxx_croatian_ci GROUP BY a;
+
+DROP TABLE maria050313_ucs2_croatian_ci_def;
+DROP TABLE maria050313_utf8_croatian_ci;
+DROP TABLE maria050533_xxx_croatian_ci;
+DROP TABLE maria100004_xxx_croatian_ci;
+DROP TABLE mysql050614_xxx_croatian_ci;
diff --git a/mysql-test/t/ctype_utf16_uca.test b/mysql-test/t/ctype_utf16_uca.test
index 2070d12cd1e..ee09f70fa03 100644
--- a/mysql-test/t/ctype_utf16_uca.test
+++ b/mysql-test/t/ctype_utf16_uca.test
@@ -52,6 +52,7 @@ select group_concat(c1 order by binary c1 separator '') from t1 group by c1 coll
select group_concat(c1 order by binary c1 separator '') from t1 group by c1 collate utf16_roman_ci;
select group_concat(c1 order by binary c1 separator '') from t1 group by c1 collate utf16_esperanto_ci;
select group_concat(c1 order by binary c1 separator '') from t1 group by c1 collate utf16_hungarian_ci;
+select group_concat(c1 order by binary c1 separator '') from t1 group by c1 collate utf16_croatian_mysql561_ci;
select group_concat(c1 order by binary c1 separator '') from t1 group by c1 collate utf16_croatian_ci;
select group_concat(c1 order by binary c1 separator '') from t1 group by c1 collate utf16_german2_ci;
diff --git a/mysql-test/t/ctype_utf32_uca.test b/mysql-test/t/ctype_utf32_uca.test
index f3fef1cf54c..e08e747445e 100644
--- a/mysql-test/t/ctype_utf32_uca.test
+++ b/mysql-test/t/ctype_utf32_uca.test
@@ -53,6 +53,7 @@ select group_concat(c1 order by binary c1 separator '') from t1 group by c1 coll
select group_concat(c1 order by binary c1 separator '') from t1 group by c1 collate utf32_roman_ci;
select group_concat(c1 order by binary c1 separator '') from t1 group by c1 collate utf32_esperanto_ci;
select group_concat(c1 order by binary c1 separator '') from t1 group by c1 collate utf32_hungarian_ci;
+select group_concat(c1 order by binary c1 separator '') from t1 group by c1 collate utf32_croatian_mysql561_ci;
select group_concat(c1 order by binary c1 separator '') from t1 group by c1 collate utf32_croatian_ci;
select group_concat(c1 order by binary c1 separator '') from t1 group by c1 collate utf32_german2_ci;
diff --git a/mysql-test/t/ctype_utf8mb4_uca.test b/mysql-test/t/ctype_utf8mb4_uca.test
index a84e06883ab..0b01dfc33a5 100644
--- a/mysql-test/t/ctype_utf8mb4_uca.test
+++ b/mysql-test/t/ctype_utf8mb4_uca.test
@@ -32,6 +32,7 @@ SELECT GROUP_CONCAT(c1 ORDER BY c1 SEPARATOR '') FROM t1 GROUP BY c1 COLLATE utf
SELECT GROUP_CONCAT(c1 ORDER BY c1 SEPARATOR '') FROM t1 GROUP BY c1 COLLATE utf8mb4_roman_ci;
SELECT GROUP_CONCAT(c1 ORDER BY c1 SEPARATOR '') FROM t1 GROUP BY c1 COLLATE utf8mb4_esperanto_ci;
SELECT GROUP_CONCAT(c1 ORDER BY c1 SEPARATOR '') FROM t1 GROUP BY c1 COLLATE utf8mb4_hungarian_ci;
+SELECT GROUP_CONCAT(c1 ORDER BY c1 SEPARATOR '') FROM t1 GROUP BY c1 COLLATE utf8mb4_croatian_mysql561_ci;
SELECT GROUP_CONCAT(c1 ORDER BY c1 SEPARATOR '') FROM t1 GROUP BY c1 COLLATE utf8mb4_croatian_ci;
SELECT GROUP_CONCAT(c1 ORDER BY c1 SEPARATOR '') FROM t1 GROUP BY c1 COLLATE utf8mb4_german2_ci;