Re: BUG #16570: Collation not working - Mailing list pgsql-bugs

From Tom Lane
Subject Re: BUG #16570: Collation not working
Date
Msg-id 2465507.1596580612@sss.pgh.pa.us
Whole thread Raw
In response to Re: BUG #16570: Collation not working  ("Daniel Verite" <daniel@manitou-mail.org>)
List pgsql-bugs
"Daniel Verite" <daniel@manitou-mail.org> writes:
>     PG Bug reporting form wrote:
>> The collation to order digits after latin characters from the official
>> documentation https://www.postgresql.org/docs/12/collation.html
>>
>> CREATE COLLATION digitslast (provider = icu, locale =
>> 'en-u-kr-latn-digit');

> The doc has this caveat:
> "The examples using the k* subtags require at least ICU version 54."
> Since you're using ICU 53,  the syntax mentioned above for the locale
> argument doesn't work. It doesn't error out, it's just being ignored.

It seems from this bug report that the OP copied-and-pasted *both* variants
of the example

    CREATE COLLATION digitslast (provider = icu, locale = 'en-u-kr-latn-digit');
    CREATE COLLATION digitslast (provider = icu, locale = 'en@colReorder=latn-digit');

without noticing the caveat (which is a good deal further down anyway).

I wonder if we could improve this by dropping the separate caveat and
writing each example like:

    CREATE COLLATION digitslast (provider = icu, locale = 'en-u-kr-latn-digit');
   or for ICU versions before 54,
    CREATE COLLATION digitslast (provider = icu, locale = 'en@colReorder=latn-digit');

That'd be a little repetitive, but there are only five such examples,
and it'd be way harder to mistake the meaning then.

            regards, tom lane



pgsql-bugs by date:

Previous
From: PG Bug reporting form
Date:
Subject: BUG #16573: pgbouncer 1.14 addition to EL6 breaks installation
Next
From: Arnaud Perrier
Date:
Subject: Re: BUG #16570: Collation not working