Re: utf8 vs UTF-8

2024-05-18 Thread Tom Lane
Adrian Klaver writes: > On 5/18/24 07:48, Troels Arvin wrote: >> Also, when I try to create a database with "en_US.utf8" as locale >> without specifying a template: >> >> troels=# create database test4 locale 'en_US.utf8'; >> ERROR:  new collation (en_US.utf8) is incompatible with the collation

Re: utf8 vs UTF-8

2024-05-18 Thread Adrian Klaver
On 5/18/24 07:48, Troels Arvin wrote: Hello, Tom Lane wrote: >>  test1  | loc_test | UTF8   | libc | en_US.UTF-8 | en_US.UTF-8 >>  test3  | troels   | UTF8   | libc | en_US.utf8  | en_US.utf8 > > On most if not all platforms, both those spellings of the locale names > will be taken

Re: utf8 vs UTF-8

2024-05-18 Thread Troels Arvin
Hello, Tom Lane wrote: >>  test1  | loc_test | UTF8   | libc | en_US.UTF-8 | en_US.UTF-8 >>  test3  | troels   | UTF8   | libc | en_US.utf8  | en_US.utf8 > > On most if not all platforms, both those spellings of the locale names > will be taken as valid.  You might try running "locale -a"

Re: utf8 vs UTF-8

2024-05-18 Thread Troels Arvin
Hellok Hans Schou wrote:   > test3   | troels   | UTF8 | libc | en_US.utf8 |  en_US.utf8 [...]   how did you create test3? For this example, I used specified it at creation time: CREATE DATABASE test3 TEMPLATE template0 LOCALE 'en_US.utf8'; In the real-world example I'm working wit

Re: utf8 vs UTF-8

2024-05-17 Thread Tom Lane
Troels Arvin writes: > In a Postgres installation, I have databases where the locale is > slightly different. Which one is correct? Excerpt from "psql --list": >  test1   | loc_test | UTF8 | libc    | en_US.UTF-8 | > en_US.UTF-8 >  test3   | troels   | UTF8 | libc 

Re: utf8 vs UTF-8

2024-05-17 Thread Hans Schou
> test3 | troels | UTF8 | libc| en_US.utf8 | en_US.utf8 It is wrong but I guess it's working? how did you create test3? On Fri, May 17, 2024 at 2:44 PM Troels Arvin wrote: > Hello, > > In a Postgres installation, I have databases where the locale is > slightly different