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 1nyfkU-0006mm-9k for pgsql-hackers@arkaria.postgresql.org; Tue, 07 Jun 2022 20:24:22 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1nyfkT-00012i-7Z for pgsql-hackers@arkaria.postgresql.org; Tue, 07 Jun 2022 20:24:21 +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 1nyfkS-00012Y-Rh for pgsql-hackers@lists.postgresql.org; Tue, 07 Jun 2022 20:24:20 +0000 Received: from mail-pl1-x633.google.com ([2607:f8b0:4864:20::633]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1nyfkQ-0005Ob-9T for pgsql-hackers@postgresql.org; Tue, 07 Jun 2022 20:24:19 +0000 Received: by mail-pl1-x633.google.com with SMTP id t2so15781210pld.4 for ; Tue, 07 Jun 2022 13:24:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ardentperf-com.20210112.gappssmtp.com; s=20210112; h=message-id:date:mime-version:user-agent:subject:content-language:to :cc:references:from:in-reply-to:content-transfer-encoding; bh=izZIN9dbArMN4Z6wUfC36Tj9Z2yGXCxY/27EnkAEJlg=; b=DUy6yM87NiK1A/1ZdXL9UNFMUbvpscA7/ajn4rrHlUKiVh96QpFgiPIIbS2yQ0iT1v jAEXh/Fo0pp0Ol0wCjOSp2yNXncTD1/edNmSgbWJ7gxI3s6OxdV9uVy2x1MgwwhVjiHx qv0kFt0spOpiW4JXBZGPgsbE6ONcAdX2i/Fpj4KXzNcSwx+MMH+Lu8r8KSHUizh3jScX MK4ESpkjSFcNJnXZBGNquT+rykYgtJuWCS/AYFvr51WXRybzWHV5H5+FFWcJQAxlgjF4 2Wlz468mUQrh91H9gW3Y0LxC33rVkxu0w+PuURUaiFPdnf03qE5YT3UDIaHivw0zIMER gPkg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:message-id:date:mime-version:user-agent:subject :content-language:to:cc:references:from:in-reply-to :content-transfer-encoding; bh=izZIN9dbArMN4Z6wUfC36Tj9Z2yGXCxY/27EnkAEJlg=; b=r/MkcvzF0sAIxfOVNMxumMdKTkQ7likqmhoTOiyYfQFcAZRkyHogIqW7zW92Zdjxmp 3/w0wJ13vm4qxLGXt3Bo1QzuU2R9C1LV6E8uyZoHVlG5wr4IF0SHhs6LEmNaI9yL9gHY 2X5lEhahtqIjJ8Bm8PDUIqnHgbEBCuVd7Jkpw4FvE+EiLR0TneNQ9+odUQVzFoV9YVmj vAXp06/7S/OdgWu64MV3lR6wTsRgTHLSr88ReeXuxywPtkmajdvcQBapfje+Ny2mtwH3 iYc4bLWtvW4b3we6m9RR0vGr/toj8IKriXg6Y4EuofbMa41UPyKd/vsKphvIKFQoSkBw sI1w== X-Gm-Message-State: AOAM533PwJE5WkkSCQV60ZRz7i52QzUX6YfVhhSLinoSW5CQBZj1PqoU n1ZCKUCBqxdQqnqSwIawImlQrQ== X-Google-Smtp-Source: ABdhPJxiM2aEaXswTFQZghUKOLRIkzGBT5gKcE4u/WjjDSBdK03Q7Kp+rEswvSzONEKlsE0k0gRrxQ== X-Received: by 2002:a17:903:2303:b0:166:313f:a85f with SMTP id d3-20020a170903230300b00166313fa85fmr30980495plh.57.1654633457011; Tue, 07 Jun 2022 13:24:17 -0700 (PDT) Received: from [10.52.182.75] (54-240-196-184.amazon.com. [54.240.196.184]) by smtp.gmail.com with ESMTPSA id 21-20020a170902c21500b00163bfaf0b17sm10997585pll.233.2022.06.07.13.24.16 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 07 Jun 2022 13:24:16 -0700 (PDT) Message-ID: Date: Tue, 7 Jun 2022 13:24:15 -0700 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:91.0) Gecko/20100101 Thunderbird/91.9.1 Subject: Re: Collation version tracking for macOS Content-Language: en-US To: Peter Geoghegan , Robert Haas Cc: Tom Lane , Thomas Munro , Peter Eisentraut , pgsql-hackers References: <381977b1-0898-cb6f-a427-3b5d873e81bd@enterprisedb.com> <231072.1654273317@sss.pgh.pa.us> <1874de62-6bec-4bc1-1d14-0a2730b125da@ardentperf.com> <366234.1654289888@sss.pgh.pa.us> From: Jeremy Schneider In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On 6/7/22 12:53 PM, Peter Geoghegan wrote: > > Collations by their very nature are unlikely to change all that much. > Obviously they can and do change, but the details are presumably > pretty insignificant to a native speaker. This idea does seem to persist. It's not as frequent as timezones, but collation rules reflect local dialects and customs, and there are changes quite regularly for a variety of reasons. A brief perusal of CLDR changelogs and CLDR jiras can give some insight here: https://github.com/unicode-org/cldr https://unicode-org.atlassian.net/jira/software/c/projects/CLDR/issues/?jql=project%20%3D%20%22CLDR%22%20AND%20text%20~%20%22collation%22%20ORDER%20BY%20created%20DESC The difference between the unicode consortium and the GNU C Library is that unicode is maintained by people who are specifically interested in working with language and internationalization challenges. I've spoken to a glibc maintainer who directly told me that they dislike working with the collation code, and try to avoid it. It's not even ISO 14651 anymore with so many custom glibc-specific changes layered on top. I looked at the first few commits in the glibc source that were responsible for the big 2.28 changes - there were a serious of quite a few commits and some were so large they wouldn't even load in the github API. Here's one such commit: https://github.com/bminor/glibc/commit/9479b6d5e08eacce06c6ab60abc9b2f4eb8b71e4 It's reasonable to expect that Red Hat and Debian will keep things stable on one particular major, and to expect that every new major OS version will update to the latest collation algorithms and locale data for glibc. Another misunderstanding that seems to persist is that this only relates to exotic locales or that it's only the 2.28 version. My github repo is out-of-date (I know of more cases that I still need to publish) but the old data already demonstrates changes to the root/DUCET collation rules (evident in en_US without any tailoring) for glibc versions 2.13, 2.21 and 2.26 https://github.com/ardentperf/glibc-unicode-sorting/ If a PosgreSQL user is unlucky enough to have one of those unicode characters stored in a table, they can get broken indexes even if they only use the default US english locale, and without touching glibc 2.28 - and all you need is an index on a field where end users can type any string input. > It's pretty clear that glibc as a project doesn't take the issue very > seriously, because they see it as a problem of the GUI sorting a table > in a way that seems slightly suboptimal to scholars of a natural > language. I disagree that glibc maintainers are doing anything wrong. While the quality of glibc collations aren't great when compared with CLDR, I think the glibc maintainers have done versioning exactly right: they are clear about which patches are allowed to contain collation updates, and the OS distributions are able to ensure stability on major OS release. I haven't yet found a Red Hat minor release that changed glibc collation. -Jeremy -- http://about.me/jeremy_schneider