BUG #15892: URGENT: Using an ICU collation in a primary key column breaks ILIKE query
От | PG Bug reporting form |
---|---|
Тема | BUG #15892: URGENT: Using an ICU collation in a primary key column breaks ILIKE query |
Дата | |
Msg-id | 15892-e5d2bea3e8a04a1b@postgresql.org обсуждение исходный текст |
Ответы |
Re: BUG #15892: URGENT: Using an ICU collation in a primary keycolumn breaks ILIKE query
|
Список | pgsql-bugs |
The following bug has been logged on the website: Bug reference: 15892 Logged by: James Inform Email address: james.inform@pharmapp.de PostgreSQL version: 11.4 Operating system: Linux Mint 19 Tara / Mac OS X 10.13.6 Description: -- This is tested under Linux Mint 19 Tara with uconv v2.1 ICU 60.2 -- and Mac OS X 10.13.6 with uconv v2.1 ICU 58.2 -- PostgreSQL Version 11.4 -- PostgreSQL was built with: ./configure '--prefix=/home/myself/pg114' '--with-systemd' '--with-icu' '--with-libxml' '--with-libxslt' '--with-perl' '--with-python' '--disable-rpath' '--with-extra-version= ICU' -- STEPS to reproduce -- First you need PostgreSQL 11.4 built with ICU support create database testdb; \c testdb; -- Just create a simple table with one column create table icutest(data text not null collate "de-x-icu" primary key); -- Insert a record with uppercase string insert into icutest values ('MYTEST'); -- This is not giving a match select * from icutest where data ilike 'mytest'; -- These two queries give the exspected result select * from icutest where lower(data) ilike 'mytest'; select * from icutest where data ilike ('mytest' collate "default"); -- If you do the same with a non primary source column, then everything works like exspected -- I'm not an Expert, but maybe the index behind the primary key is based on the wrong collation
В списке pgsql-bugs по дате отправления: