On Mon, Sep 25, 2017 at 11:42 AM, Peter Eisentraut <peter.eisentr...@2ndquadrant.com> wrote: > On 9/25/17 00:24, Peter Geoghegan wrote: >> * Creates root collation as root-x-icu (collcollate "root"), not >> und-x-icu. "und" means undefined language. > > I'm curious about this point. "und" is defined in BCP 47. I don't see > "root" defined anywhere. ICU converts the root collation to "und", > AFAIK, so it seems to agree with the current naming.
In my patch, "root" is a string that is passed to get a language tag. That's technically in the old format. I think that this is another ICU vs. UCA/CLDR thing (this causes much confusion). Note that "root" is mentioned in the ICU locale explorer, for example: https://ssl.icu-project.org/icu-bin/locexp Note also that ucol_open() comments/docs say this: * @param loc The locale containing the required collation rules. * Special values for locales can be passed in - * if NULL is passed for the locale, the default locale * collation rules will be used. If empty string ("") or * "root" are passed, UCA rules will be used. I went with "root" because that produces a meaningful/useful display name for pg_collation, and seems to be widely used elsewhere. -- Peter Geoghegan -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers