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 1nFdbJ-0001Au-Bd for pgsql-general@arkaria.postgresql.org; Thu, 03 Feb 2022 15:00:45 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1nFdbH-000475-VD for pgsql-general@arkaria.postgresql.org; Thu, 03 Feb 2022 15:00:43 +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 1nFdbH-00046w-L5 for pgsql-general@lists.postgresql.org; Thu, 03 Feb 2022 15:00:43 +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 1nFdbF-0002mk-Ac for pgsql-general@lists.postgresql.org; Thu, 03 Feb 2022 15:00:43 +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 213F0b5b253778; Thu, 3 Feb 2022 10:00:38 -0500 From: Tom Lane To: Matthias Apitz cc: pgsql-general@lists.postgresql.org Subject: Re: sort order for UTF-8 char column with Japanese UTF-8 In-reply-to: References: Comments: In-reply-to Matthias Apitz message dated "Thu, 03 Feb 2022 11:51:27 +0100" MIME-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-ID: <253776.1643900437.1@sss.pgh.pa.us> Content-Transfer-Encoding: quoted-printable Date: Thu, 03 Feb 2022 10:00:37 -0500 Message-ID: <253777.1643900437@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Matthias Apitz writes: > El d=C3=ADa jueves, febrero 03, 2022 a las 11:14:55 +0100, Matthias Apit= z escribi=C3=B3: >> With ESQL/C on a PostgreSQL 13.1 server I see the result of this query: >> select katkey,normform from swd_anzeige where normform >=3D 'A' ORDER B= Y ASC; >> coming out in this order: >> ... >> I loaded the same table in my server, but can't get the same order with >> psql: Do the two machines produce the same results if you sort the data in question with sort(1)? (Being careful to set LANG=3Dde_DE.UTF-8 of course.) I rather doubt this has anything to do with Postgres as such; there are lots of inter-system and inter-release discrepancies in collation behavior. regards, tom lane