Dear Members!

Today we found strange database collation names in a server (V11).

select -- datname,
       distinct datcollate
from pg_database
order by datcollate --, datname;

"hu_HU.UTF-8"
"hu_HU.UTF8"
"hu_HU.utf8"


The PGAdmin also gives us these possible collations in the dialog.
Some of the databases were migrated from 9.6 by Python script, and we used
   "hu_HU.UTF-8"
to create the empty databases before restoring them.

What I don't understand, that if I query for collations, I got only this:

SELECT *
FROM pg_collation
where upper(collname) like '%HU%' -- and upper(collname) like '%UTF%'
order by collname

hu_HU.utf8


This collation ("hu_HU.UTF-8") doesn't cause any problems, and PGSQL V11
accepts it.

The whole problem appeared when we wanted to copy a database to a new (with
defining the old as template).

*Error: new collation (hu_HU.utf8) is incompatible with the collation of
the template database (hu_HU.UTF-8)*


So maybe the UTF-8 isn't valid but the PG accepted that???
Or is it valid and inherited from 9.6?

Please help me a little bit! Thank you!

Best regards
dd

Reply via email to