Re: Uppercase version of ß desired

From: "Peter J(dot) Holzer" <hjp-pgsql(at)hjp(dot)at>
To: pgsql-general(at)lists(dot)postgresql(dot)org
Subject: Re: Uppercase version of ß desired
Date: 2023-03-13 22:45:05
Message-ID: 20230313224505.snjtnuz75s76w3zi@hjp.at
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On 2023-03-13 17:38:51 -0400, Celia McInnis wrote:
> I would be really happy if postgresql  had an upper case version of the ß
> german character. The wiki page
> https://en.wikipedia.org/wiki/%C3%9F
>
> indicates that the capital (U+1E9E ẞ LATIN CAPITAL LETTER SHARP S) was encoded
> by ISO 10646 in 2008.

The character is there, of course, and lower-casing it works as
expected:

hjp=> select 'ẞ', lower('ẞ');
╔══════════╤═══════╗
║ ?column? │ lower ║
╟──────────┼───────╢
║ ẞ │ ß ║
╚══════════╧═══════╝
(1 row)

But the 'ß' is a bit special as it is usually uppercased to 'SS'
(although 'ẞ' is now officially allowed, too).

Apparently your (and my) locale doesn't uppercase ß at all, which isn't
correct according to German spelling rules but was very common in the
last decades.

You can specify an alternate locale:

hjp=> select upper('ß');
╔═══════╗
║ upper ║
╟───────╢
║ ß ║
╚═══════╝
(1 row)

hjp=> select upper('ß' collate "de-AT-x-icu");
╔═══════╗
║ upper ║
╟───────╢
║ SS ║
╚═══════╝
(1 row)

The challenge now is to find a locale which uppercases ß to ẞ.

hp

--
_ | Peter J. Holzer | Story must make more sense than reality.
|_|_) | |
| | | hjp(at)hjp(dot)at | -- Charles Stross, "Creative writing
__/ | http://www.hjp.at/ | challenge!"

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Tom Lane 2023-03-13 22:54:43 Re: Uppercase version of ß desired
Previous Message Michael Downey 2023-03-13 22:12:51 Using GSSAPI/Kerbros/Active Directory: want the database user name to be the full name including the realm name without specifying the user