From: Tom Lane <tgl@sss.pgh.pa.us>
To: Oleksandr Voytsekhovskyy <young.inbox@gmail.com>
Cc: PostgreSQL General <pgsql-general@lists.postgresql.org>
Subject: Re: Wrong sorting on docker image
Date: Sat, 16 Oct 2021 11:42:02 -0400
Message-ID: <1061942.1634398922@sss.pgh.pa.us> (raw)
In-Reply-To: <F29709C9-A061-4034-A77D-7E237CF36391@gmail.com>
References: <F29709C9-A061-4034-A77D-7E237CF36391@gmail.com>
Oleksandr Voytsekhovskyy <young.inbox@gmail.com> writes:
> Starting from version 12.0 official docker image switched from Debian-stretch to Debian-bullseye and from that point we have a huge pain with sorting issues on Russian collation.
Yeah, Debian versions after stretch adopted the significant glibc locale
data changes (sorting rule changes) that are discussed at [1].
> ея should go before ёа
I'm not qualified to have an opinion on that point, but one would hope
that the glibc people who changed the sorting rules are qualified.
If you disagree, you need to go discuss it with glibc. Postgres doesn't
define any text sorting rules, we just use what libc or ICU tells us.
Speaking of ICU, if you are using an ICU-enabled Postgres build,
maybe you could find an ICU collation that acts the way you want.
This wouldn't be a perfect solution, because we don't yet have
the ability to set an ICU collation as a database's default.
But you can attach ICU collations to individual text columns,
and maybe that would be a good enough workaround.
regards, tom lane
[1] https://wiki.postgresql.org/wiki/Locale_data_changes
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-general@postgresql.org
Cc: tgl@sss.pgh.pa.us, young.inbox@gmail.com
Subject: Re: Wrong sorting on docker image
In-Reply-To: <1061942.1634398922@sss.pgh.pa.us>
References: <F29709C9-A061-4034-A77D-7E237CF36391@gmail.com> <1061942.1634398922@sss.pgh.pa.us>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox