Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1ph7Zn-00012M-Jl for pgsql-hackers@arkaria.postgresql.org; Tue, 28 Mar 2023 11:33:19 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1ph7Zl-0007xX-3J for pgsql-hackers@arkaria.postgresql.org; Tue, 28 Mar 2023 11:33:17 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1ph7Zk-0007xN-QI for pgsql-hackers@lists.postgresql.org; Tue, 28 Mar 2023 11:33:16 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1ph7Ze-0004VV-7M for pgsql-hackers@postgresql.org; Tue, 28 Mar 2023 11:33:16 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.15.2/8.15.2) with ESMTP id 32SBX6iL3440246; Tue, 28 Mar 2023 07:33:06 -0400 From: Tom Lane To: Peter Eisentraut cc: pgsql-hackers Subject: Re: Move definition of standard collations from initdb to pg_collation.dat In-reply-to: <08b58ecd-0d50-9395-ed51-dc8294e3fd2b@enterprisedb.com> References: <08b58ecd-0d50-9395-ed51-dc8294e3fd2b@enterprisedb.com> Comments: In-reply-to Peter Eisentraut message dated "Tue, 28 Mar 2023 12:19:57 +0200" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <3440244.1680003186.1@sss.pgh.pa.us> Date: Tue, 28 Mar 2023 07:33:06 -0400 Message-ID: <3440245.1680003186@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Peter Eisentraut writes: > While working on [0], I was wondering why the collations ucs_basic and > unicode are not in pg_collation.dat. I traced this back through > history, and I think this was just lost in a game of telephone. > The initial commit for pg_collation.h (414c5a2ea6) has only the default > collation in pg_collation.h (pre .dat), with initdb handling everything > else. Over time, additional collations "C" and "POSIX" were moved to > pg_collation.h, and other logic was moved from initdb to > pg_import_system_collations(). But ucs_basic was untouched. Commit > 0b13b2a771 rearranged the relative order of operations in initdb and > added the current comment "We don't want to pin these", but looking at > the email[1], I think this was more a guess about the previous intent. Yeah, I was just loath to change the previous behavior in that patch. I can't see any strong reason not to pin these entries. > I suggest we fix this now; see attached patch. While we're here, do we want to adopt some other spelling of "the root locale" than "und", in view of recent discoveries about the instability of that on old ICU versions? regards, tom lane