Re: ERROR: new collation (en_US.UTF-8) is incompatible with the collation of the template database (en_US.utf-8)

2022-06-24 Thread Tom Lane
Peter Eisentraut writes: > There are also cases where on one system the locale is spelled > xx_YY.UTF8 and on another xx_YY.UTF-8. If we start adjusting for case, > should we adjust for this as well? What other cases are there? > So this would need a bit more research. Yeah. I would tend to

Re: ERROR: new collation (en_US.UTF-8) is incompatible with the collation of the template database (en_US.utf-8)

2022-06-24 Thread Peter Eisentraut
On 23.06.22 20:21, Adrian Klaver wrote: Not sure why that is necessary? Is seems this is low hanging fruit that could dealt with by the equivalent of lower('en_US.UTF-8') = lower('en_US.utf-8'). Well that was clear as mud. My point was that I don't see why the end user should have to do this

Re: ERROR: new collation (en_US.UTF-8) is incompatible with the collation of the template database (en_US.utf-8)

2022-06-24 Thread Tomas Pospisek
On 23.06.22 20:21, Adrian Klaver wrote: On 6/23/22 10:11, Adrian Klaver wrote: On 6/23/22 00:37, Tomas Pospisek wrote: On 22.06.22 22:18, Tomas Pospisek wrote: On 22.06.22 21:25, Adrian Klaver wrote: On 6/22/22 12:17, Tomas Pospisek wrote: So I used both pg_dump and pg_restore from the

Re: ERROR: new collation (en_US.UTF-8) is incompatible with the collation of the template database (en_US.utf-8)

2022-06-23 Thread Adrian Klaver
On 6/23/22 10:11, Adrian Klaver wrote: On 6/23/22 00:37, Tomas Pospisek wrote: On 22.06.22 22:18, Tomas Pospisek wrote: On 22.06.22 21:25, Adrian Klaver wrote: On 6/22/22 12:17, Tomas Pospisek wrote: So I used both pg_dump and pg_restore from the newer machine. Result is still the same. 

Re: ERROR: new collation (en_US.UTF-8) is incompatible with the collation of the template database (en_US.utf-8)

2022-06-23 Thread Adrian Klaver
On 6/23/22 00:37, Tomas Pospisek wrote: On 22.06.22 22:18, Tomas Pospisek wrote: On 22.06.22 21:25, Adrian Klaver wrote: On 6/22/22 12:17, Tomas Pospisek wrote: So I used both pg_dump and pg_restore from the newer machine. Result is still the same.  So I'll use Tom Lane's suggestion too

Re: ERROR: new collation (en_US.UTF-8) is incompatible with the collation of the template database (en_US.utf-8)

2022-06-23 Thread Tomas Pospisek
On 22.06.22 22:18, Tomas Pospisek wrote: On 22.06.22 21:25, Adrian Klaver wrote: On 6/22/22 12:17, Tomas Pospisek wrote: Hi all, while doing `cat pg_dump.dump | psql` I get the above message. Note that `pg_dump.dump` contains: CREATE DATABASE some_db WITH TEMPLATE = my_own_template

Re: ERROR: new collation (en_US.UTF-8) is incompatible with the collation of the template database (en_US.utf-8)

2022-06-22 Thread Tom Lane
Tomas Pospisek writes: > On 22.06.22 21:25, Adrian Klaver wrote: >> On 6/22/22 12:17, Tomas Pospisek wrote: >>> If I `pg_dump --create` some DB on the new server (13.7-1.pgdg18.04+1) >>> I get: >>> >>> CREATE DATABASE ... ENCODING = 'UTF8' LOCALE = 'en_US.utf-8'; >>> >>> When I do the

Re: ERROR: new collation (en_US.UTF-8) is incompatible with the collation of the template database (en_US.utf-8)

2022-06-22 Thread Tomas Pospisek
On 22.06.22 21:25, Adrian Klaver wrote: On 6/22/22 12:17, Tomas Pospisek wrote: Hi all, while doing `cat pg_dump.dump | psql` I get the above message. Note that `pg_dump.dump` contains: CREATE DATABASE some_db WITH TEMPLATE = my_own_template ENCODING = 'UTF8' LC_COLLATE =

Re: ERROR: new collation (en_US.UTF-8) is incompatible with the collation of the template database (en_US.utf-8)

2022-06-22 Thread Adrian Klaver
On 6/22/22 12:17, Tomas Pospisek wrote: Hi all, while doing `cat pg_dump.dump | psql` I get the above message. Note that `pg_dump.dump` contains:     CREATE DATABASE some_db WITH TEMPLATE = my_own_template ENCODING = 'UTF8' LC_COLLATE = 'en_US.UTF-8' LC_CTYPE = 'en_US.UTF-8'; What is

ERROR: new collation (en_US.UTF-8) is incompatible with the collation of the template database (en_US.utf-8)

2022-06-22 Thread Tomas Pospisek
Hi all, while doing `cat pg_dump.dump | psql` I get the above message. Note that `pg_dump.dump` contains: CREATE DATABASE some_db WITH TEMPLATE = my_own_template ENCODING = 'UTF8' LC_COLLATE = 'en_US.UTF-8' LC_CTYPE = 'en_US.UTF-8'; What is exactly the problem? I understand that