| From: | "Daniel Verite" <daniel(at)manitou-mail(dot)org> |
|---|---|
| To: | "Robert Haas" <robertmhaas(at)gmail(dot)com> |
| Cc: | "Jeff Davis" <pgsql(at)j-davis(dot)com>,pgsql-hackers(at)postgresql(dot)org |
| Subject: | Re: Change initdb default to the builtin collation provider |
| Date: | 2026-03-11 16:28:05 |
| Message-ID: | ec3d1357-d8c4-47d1-887b-ec2f0b8a7e67@manitou-mail.org |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
Robert Haas wrote:
> To be honest, I'd probably be ready to support making the default
> encoding UTF8 regardless of the environment, and you have to use -E
> if you want anything else. I think there are still people using
> other encodings, but I believe it to be a small minority at this
> point.
It would be interesting to have the point of view of Asian users about
this. Recently, the suggestion to retire GB18030 in favor of UTF-8 was
met with the objection that GB18030 was likely preferred by users from
China [1]. Another example against UTF-8 that I found notable, is
Tatsuo Ishii mentioning that Japanese users tend use --no-locale
rather than UTF-8 locales [2].
Also, it's not obvious how initdb could choose an UTF-8 locale
regardless of the environment.
For instance, let's say it finds LC_ALL="fr_FR(dot)iso885915(at)euro", what
would it do? Maybe look at the UTF-8 locales on the system. Here's a
subset of what it would find on my system:
C.utf8
en_AG
en_AG.utf8
en_AU.utf8
en_BW.utf8
en_CA.utf8
en_DK.utf8
en_GB.utf8
en_HK.utf8
en_IE.utf8
...
tr_TR.utf8
From that kind of list, which locale should it pick and why?
Personally I think that ignoring the environment's LC_* for the
collations would be fine if we went for builtin/C.UTF-8 by default, as
$subject suggests. But the level of enthusiasm for that from the
community seems much lower than it would need to be for that kind of
change to be acceptable.
[1]
https://www.postgresql.org/message-id/45b4b689-0e78-4d30-a5f9-1a39d01ab2b7%40ww-it.cn
[2]
https://www.postgresql.org/message-id/20230608.104535.2171011311090815110.t-ishii%40sranhm.sra.co.jp
Best regards,
--
Daniel Vérité
https://postgresql.verite.pro/
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Greg Sabino Mullane | 2026-03-11 16:39:19 | Re: ALTER TABLE: warn when actions do not recurse to partitions |
| Previous Message | Tomas Vondra | 2026-03-11 16:18:19 | Re: Fix typo 586/686 in atomics/arch-x86.h |