Am 08.06.2022 um 16:16 schrieb Tom Lane <t...@sss.pgh.pa.us>:
> The proposed patch would result in a warning about every collation-
> sensitive index during every macOS major version upgrade, ie about
> once a year for most people.  
> We need something that has at least *some* connection to actual changes.

In Postgres.app we introduced default collation versioning and warnings about 
possible mismatches from outside the actual server. When the user runs initdb 
with the GUI wrapper, the OS version and a checksum of the LC_COLLATE file of 
the used default collation is stored as meta-data. This allows to display a 
reindex warning on startup if the hash changes or we hardcode a known 
incompatible OS change.

Having collversion support on macOS within postgres would leverage the existing 
infrastructure for version change warnings and enables support for multiple 
collations. But I agree, we need something more specific than the major OS 
version here. Lacking any collation version information from the provider, a 
checksum on the binary LC_COLLATE file is the best I can come up with. 

Best regards,
Tobias

Reply via email to