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 1oZRGH-0006zE-OF for pgsql-hackers@arkaria.postgresql.org; Sat, 17 Sep 2022 06:25:10 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1oZRGG-0000YK-AV for pgsql-hackers@arkaria.postgresql.org; Sat, 17 Sep 2022 06:25:08 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oZRGF-0000XZ-RJ for pgsql-hackers@lists.postgresql.org; Sat, 17 Sep 2022 06:25:08 +0000 Received: from mail.postgrespro.ru ([93.174.131.139]) by makus.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1oZRGB-0004GL-Iw for pgsql-hackers@postgresql.org; Sat, 17 Sep 2022 06:25:06 +0000 Received: from mail.postgrespro.ru (cyclops.postgrespro.ru [93.174.131.138]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client did not present a certificate) by mail.postgrespro.ru (Postfix) with ESMTPSA id D586021C04FB; Sat, 17 Sep 2022 09:25:00 +0300 (MSK) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=postgrespro.ru; s=mail; t=1663395900; bh=B8YncEzYS/pWZieNbOdI2eZ5cEY26IHJmoxl4pRy9sU=; h=Date:From:To:Cc:Subject:In-Reply-To:References; b=H1dLY1X7NPRcoViVmItmAsQzd2wsZRU+1epjUaLDMzHHgJD6HVxrwJh0XPRBb7j/p HvrX9afenGqerUZSufTw+M5y0XH+j60oGo84Mjuxm2FMPxURz4BrMRa057CBdvreL6 Yn5fA6Et7NMLKXyOrdnIpN6Pu70YdQYNSKTvk9PI= MIME-Version: 1.0 Date: Sat, 17 Sep 2022 09:25:00 +0300 From: Marina Polyakova To: Peter Eisentraut Cc: Kyotaro Horiguchi , pgsql-hackers@postgresql.org, pryzby@telsasoft.com, rjuju123@gmail.com, daniel@manitou-mail.org, AndrewBille@gmail.com, michael@paquier.xyz Subject: Re: ICU for global collation In-Reply-To: References: <6dd6db0984d86a51b7255ba79f111971@postgrespro.ru> <20220915.155210.529619933474389138.horikyota.ntt@gmail.com> <2322791a368e9ad066edd648790b5e91@postgrespro.ru> <20220916.135519.1552320805811493586.horikyota.ntt@gmail.com> <1989d430b926be3c08735f97fffc6294@postgrespro.ru> User-Agent: Roundcube Webmail/1.4.11 Message-ID: X-Sender: m.polyakova@postgrespro.ru Organization: Postgres Professional Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On 2022-09-16 10:57, Peter Eisentraut wrote: > On 16.09.22 09:31, Marina Polyakova wrote: >> IMO it is hardly understantable from the program output either - it >> looks like I manually chose the encoding UTF8. Maybe first inform >> about selected encoding?.. > > Yes, I included something like that in the patch just committed. > >> diff --git a/src/bin/initdb/initdb.c b/src/bin/initdb/initdb.c >> index >> 6aeec8d426c52414b827686781c245291f27ed1f..348bbbeba0f5bc7ff601912bf883510d580b814c >> 100644 >> --- a/src/bin/initdb/initdb.c >> +++ b/src/bin/initdb/initdb.c >> @@ -2310,7 +2310,11 @@ setup_locale_encoding(void) >>      } >> >>      if (!encoding && locale_provider == COLLPROVIDER_ICU) >> +    { >>          encodingid = PG_UTF8; >> +        printf(_("The default database encoding has been set to >> \"%s\" for a better experience with the ICU provider.\n"), >> +               pg_encoding_to_char(encodingid)); >> +    } >>      else if (!encoding) >>      { >>          int            ctype_enc; Thank you! -- Marina Polyakova Postgres Professional: http://www.postgrespro.com The Russian Postgres Company