Description:
When I add new collation utf8_test_ci into server file share\charsets\Index.xml
an restart mysql server I can find new collation but create table
with this collation is ending with error "Unknown collation: 'utf8_test_ci'"
How to repeat:
Test Code:
------==========================================================-----
1. Insert new collation into utf8 section into file share\charsets\Index.xml
<collation name="utf8_test_ci" id="222">
<rules>
<reset>A</reset><p>\u00e1</p><t>\u00c1</t><p>\u00e4</p><t>\u00c4</t>
<reset>C</reset><p>\u010d</p><t>\u010c</t>
<reset>D</reset><p>\u010f</p><t>\u010e</t><p>dz</p><t>Dz</t><t>DZ</t><p>\u0064\u017e</p><t>\u0044\u017e</t><t>\u0044\u017d</t>
<reset>E</reset><p>\u00e9</p><t>\u00c9</t>
<reset>H</reset><p>ch</p><t>Ch</t><t>CH</t>
<reset>I</reset><p>\u00ed</p><t>\u00cd</t>
<reset>L</reset><p>\u013a</p><t>\u0139</t><p>\u013e</p><t>\u013d</t>
<reset>N</reset><p>\u0148</p><t>\u0147</t>
<reset>O</reset><p>\u00f3</p><t>\u00d3</t><p>\u00f4</p><t>\u00d4</t>
<reset>R</reset><p>\u0155</p><t>\u0154</t>
<reset>S</reset><p>\u0161</p><t>\u0160</t>
<reset>T</reset><p>\u0165</p><t>\u0164</t>
<reset>U</reset><p>\u00fa</p><t>\u00da</t>
<reset>Y</reset><p>\u00fd</p><t>\u00dd</t>
<reset>Z</reset><p>\u017e</p><t>\u017d</t>
</rules>
</collation>
2.
mysql> SHOW COLLATION like "%test%";
+--------------+---------+-----+---------+----------+---------+
| Collation | Charset | Id | Default | Compiled | Sortlen |
+--------------+---------+-----+---------+----------+---------+
| utf8_test_ci | utf8 | 250 | | | 8 |
+--------------+---------+-----+---------+----------+---------+
1 row in set (0.00 sec)
3. Create table
CREATE TABLE sk_test
(ID INT NOT NULL AUTO_INCREMENT ,
hodnota VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_test_ci not null,
PRIMARY KEY (ID)
) ENGINE=InnoDB CHARACTER SET utf8 COLLATE utf8_test_ci ;
Problem is Many-characters-to-one-weight, becouse when i deleted this sequence
<p>\u0064\u017e</p><t>\u0044\u017e</t><t>\u0044\u017d</t>
table was created
Description: When I add new collation utf8_test_ci into server file share\charsets\Index.xml an restart mysql server I can find new collation but create table with this collation is ending with error "Unknown collation: 'utf8_test_ci'" How to repeat: Test Code: ------==========================================================----- 1. Insert new collation into utf8 section into file share\charsets\Index.xml <collation name="utf8_test_ci" id="222"> <rules> <reset>A</reset><p>\u00e1</p><t>\u00c1</t><p>\u00e4</p><t>\u00c4</t> <reset>C</reset><p>\u010d</p><t>\u010c</t> <reset>D</reset><p>\u010f</p><t>\u010e</t><p>dz</p><t>Dz</t><t>DZ</t><p>\u0064\u017e</p><t>\u0044\u017e</t><t>\u0044\u017d</t> <reset>E</reset><p>\u00e9</p><t>\u00c9</t> <reset>H</reset><p>ch</p><t>Ch</t><t>CH</t> <reset>I</reset><p>\u00ed</p><t>\u00cd</t> <reset>L</reset><p>\u013a</p><t>\u0139</t><p>\u013e</p><t>\u013d</t> <reset>N</reset><p>\u0148</p><t>\u0147</t> <reset>O</reset><p>\u00f3</p><t>\u00d3</t><p>\u00f4</p><t>\u00d4</t> <reset>R</reset><p>\u0155</p><t>\u0154</t> <reset>S</reset><p>\u0161</p><t>\u0160</t> <reset>T</reset><p>\u0165</p><t>\u0164</t> <reset>U</reset><p>\u00fa</p><t>\u00da</t> <reset>Y</reset><p>\u00fd</p><t>\u00dd</t> <reset>Z</reset><p>\u017e</p><t>\u017d</t> </rules> </collation> 2. mysql> SHOW COLLATION like "%test%"; +--------------+---------+-----+---------+----------+---------+ | Collation | Charset | Id | Default | Compiled | Sortlen | +--------------+---------+-----+---------+----------+---------+ | utf8_test_ci | utf8 | 250 | | | 8 | +--------------+---------+-----+---------+----------+---------+ 1 row in set (0.00 sec) 3. Create table CREATE TABLE sk_test (ID INT NOT NULL AUTO_INCREMENT , hodnota VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_test_ci not null, PRIMARY KEY (ID) ) ENGINE=InnoDB CHARACTER SET utf8 COLLATE utf8_test_ci ; Problem is Many-characters-to-one-weight, becouse when i deleted this sequence <p>\u0064\u017e</p><t>\u0044\u017e</t><t>\u0044\u017d</t> table was created