Re: DROP COLLATION vs pg_collation question - Mailing list pgsql-general

From Laurenz Albe
Subject Re: DROP COLLATION vs pg_collation question
Date
Msg-id 56da532b44bc02a7648796041ffa5da0a85c06df.camel@cybertec.at
Whole thread Raw
In response to Re: DROP COLLATION vs pg_collation question  (Karsten Hilbert <Karsten.Hilbert@gmx.net>)
Responses Re: DROP COLLATION vs pg_collation question
List pgsql-general
On Fri, 2024-06-14 at 22:08 +0200, Karsten Hilbert wrote:
> Are collations per-database or per-cluster objects ?

Each database has its own "pg_collation" catalog table.

So they are local to the database, but the collations themselves
are defined by an external library, so the implementation is shared.

> I am asking because I seem to not be enabled to
>
> 3) update collation version information in pg_collations for
>    collations intended for an encoding different from the
>    database encoding (ALTER COLLATION ... REFRESH VERSION fails)
>
> which in effect would mean that -- upon change of collation
> versions in the underlying operating system (ICU update, libc
> update) -- one would have to live with outdated version
> information in pg_collations short of dump/sed/restore or
> some such ?

That should not happen.  What error do you get when you

  ALTER COLLATION ... REFRESH VERSION

Does the following give you the same error?

  ALTER DATABASE ... REFRESH COLLATION VERSION

Yours,
Laurenz Albe



pgsql-general by date:

Previous
From: Adrian Klaver
Date:
Subject: Re: Is a VACUUM or ANALYZE necessary after logical replication?
Next
From: Achilleas Mantzios
Date:
Subject: Re: Is a VACUUM or ANALYZE necessary after logical replication?