pgsql: Don't allow creation of database with ICU locale with unsupporte

From: Peter Eisentraut <peter(at)eisentraut(dot)org>
To: pgsql-committers(at)lists(dot)postgresql(dot)org
Subject: pgsql: Don't allow creation of database with ICU locale with unsupporte
Date: 2022-09-16 07:53:56
Message-ID: E1oZ6Ae-000ZUA-9g@gemulon.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Don't allow creation of database with ICU locale with unsupported encoding

Check in CREATE DATABASE and initdb that the selected encoding is
supported by ICU. Before, they would pass but users would later get
an error from the server when they tried to use the database.

Also document that initdb sets the encoding to UTF8 by default if the
ICU locale provider is chosen.

Author: Marina Polyakova <m(dot)polyakova(at)postgrespro(dot)ru>
Reviewed-by: Kyotaro Horiguchi <horikyota(dot)ntt(at)gmail(dot)com>
Discussion: https://www.postgresql.org/message-id/6dd6db0984d86a51b7255ba79f111971@postgrespro.ru

Branch
------
REL_15_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/148f66d59e2c2fa8bc79918973874e2803892664

Modified Files
--------------
doc/src/sgml/ref/initdb.sgml | 5 +++--
src/backend/commands/dbcommands.c | 9 +++++++--
src/bin/initdb/initdb.c | 29 +++++++++++++++++++++++++++++
src/bin/initdb/t/001_initdb.pl | 9 +++++++++
src/bin/scripts/t/020_createdb.pl | 9 +++++++++
5 files changed, 57 insertions(+), 4 deletions(-)

Browse pgsql-committers by date

  From Date Subject
Next Message Peter Eisentraut 2022-09-16 09:16:51 pgsql: Fix createdb tests for C locale
Previous Message Andres Freund 2022-09-16 01:54:38 warning about missing format string annotations