Li Yunfeng
Li Yunfeng

Reputation: 31

create collation of firebird(3.0.1) db error on windows but succeed on centos

I try to create a collation on a new database(firebird3.0.1 on windows. I follows the steps:

  1. create database 'c:\tmp\ebizmis.fdb' user 'SYSDBA' password '123456' default character set utf8 collation unicode;

  2. connect 'c:\tmp\ebizmis.fdb' user 'SYSDBA' password '123456';

  3. create collation py for utf8 from UNICODE case insensitive 'LOCALE=zh';

in this step, prompting error:

Statement failed, SQLSTATE = HY000
unsuccessful metadata update
-CREATE COLLATION PY failed
-Invalid collation attributes

But on CentOS it is successfull on firebird 3.0.1.

When I change the uppercase LOCALE to lowercase:

create collation py for utf8 from UNICODE case insensitive 'locale=zh';

then it can be excuted on windows, but do not work for sorting the characters in chinese pinyin order.

Upvotes: 1

Views: 269

Answers (1)

Li Yunfeng
Li Yunfeng

Reputation: 31

I cannot build Firebird 3.0.1 under windows, but I can build 2.5.6. So I debug under 2.5.6. I found there is no bug in Firebird. The cause of the problem is that I haven't include zh locale in the icu. So I download the data from icu web site and replace the file in 3.0.1. It works!

Upvotes: 2

Related Questions