Skip to content

Commit 2c4db99

Browse files
peterepull[bot]
authored andcommitted
Improve support for UNICODE collation on older ICU
The recently added standard collation UNICODE (0d21d4b) doesn't give consistent results on some build farm members with old ICU versions. Apparently, the ICU locale specification 'und' (language tag style) misbehaves on some older ICU versions. Replacing it with '' (ICU locale ID style) fixes it at least on some OS versions. Let's see what the build farm says.
1 parent 68b44b7 commit 2c4db99

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/bin/initdb/initdb.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1498,7 +1498,7 @@ setup_collation(FILE *cmdfd)
14981498
* that they win if libc defines a locale with the same name.
14991499
*/
15001500
PG_CMD_PRINTF("INSERT INTO pg_collation (oid, collname, collnamespace, collowner, collprovider, collisdeterministic, collencoding, colliculocale)"
1501-
"VALUES (pg_nextoid('pg_catalog.pg_collation', 'oid', 'pg_catalog.pg_collation_oid_index'), 'unicode', 'pg_catalog'::regnamespace, %u, '%c', true, -1, 'und');\n\n",
1501+
"VALUES (pg_nextoid('pg_catalog.pg_collation', 'oid', 'pg_catalog.pg_collation_oid_index'), 'unicode', 'pg_catalog'::regnamespace, %u, '%c', true, -1, '');\n\n",
15021502
BOOTSTRAP_SUPERUSERID, COLLPROVIDER_ICU);
15031503

15041504
PG_CMD_PRINTF("INSERT INTO pg_collation (oid, collname, collnamespace, collowner, collprovider, collisdeterministic, collencoding, collcollate, collctype)"

src/include/catalog/catversion.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,6 @@
5757
*/
5858

5959
/* yyyymmddN */
60-
#define CATALOG_VERSION_NO 202303101
60+
#define CATALOG_VERSION_NO 202303131
6161

6262
#endif

0 commit comments

Comments
 (0)