pgsql: Disallow creating an ICU collation if the DB encoding won't supp

Поиск
Список
Период
Сортировка
От Tom Lane
Тема pgsql: Disallow creating an ICU collation if the DB encoding won't supp
Дата
Msg-id E1mMFyh-0001K1-5v@gemulon.postgresql.org
обсуждение исходный текст
Список pgsql-committers
Disallow creating an ICU collation if the DB encoding won't support it.

Previously this was allowed, but the collation effectively vanished
into the ether because of the way lookup_collation() works: you could
not use the collation, nor even drop it.  Seems better to give an
error up front than to leave the user wondering why it doesn't work.

(Because this test is in DefineCollation not CreateCollation, it does
not prevent pg_import_system_collations from creating ICU collations,
regardless of the initially-chosen encoding.)

Per bug #17170 from Andrew Bille.  Back-patch to v10 where ICU support
was added.

Discussion: https://postgr.es/m/17170-95845cf3f0a9c36d@postgresql.org

Branch
------
REL_11_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/9ebe2852e5435d88d5e3d655b05887b66059cc4d

Modified Files
--------------
src/backend/commands/collationcmds.c | 19 +++++++++++++++++++
1 file changed, 19 insertions(+)


В списке pgsql-committers по дате отправления:

Предыдущее
От: John Naylor
Дата:
Сообщение: pgsql: Set the volatility of the timestamptz version of date_bin() back
Следующее
От: Tom Lane
Дата:
Сообщение: Re: pgsql: Set the volatility of the timestamptz version of date_bin() back