model-writtenrun 6191 - may be wrong, links go to the source messages. Commit-by-commit LLM analysis is in the Commits dialog.
- Andrew Bille reported that an ICU collation created in a SQL_ASCII database could neither be used nor dropped, reproducing the problem across PostgreSQL 10 through 14 branches #1.
- Tom Lane explained that encoding-sensitive collation lookup hid the unusable entry and considered either relaxing DROP COLLATION lookup or rejecting its creation #2.
- After experimentation, Tom Lane proposed rejecting CREATE COLLATION when ICU does not support the database encoding and attached a patch implementing that check #3.
- Tom Lane acknowledged that this would prevent manually adding ICU collations to an incompatible template0 for later cloning, but considered initializing with an ICU-compatible encoding a sufficient alternative; the thread ended with his proposed patch and no subsequent review replies #3.
- Tom Lane committed the patch as db2760a841, adding a USE_ICU guard and explanatory comments to #3; the fix preserved system collation import behavior and was backpatched through PostgreSQL 10.