Nondeterministic collations
Collations that can treat distinct strings as equal (case- or accent-insensitive ICU collations), later supported by LIKE, regex and POSITION, plus fixes to planner optimizations that assumed deterministic equality. Introduced in PostgreSQL 12.
Versions
- PostgreSQL 19 · worked-on · improved · moderate
- PostgreSQL 18 · shipped · improved · moderate · 2 commits · +704 / -92 lines
- PostgreSQL 17 · worked-on · improved · moderate
Threads
- BUG #19873: planner silently drops the second ORDER BY sort key when both keys reference the same expression und
- BUG #19869: Wrong results: planner silently drops the second ORDER BY sort key when both keys reference the same
- BUG #19806: Wrong results: HAVING pushed into WHERE for GROUP BY on composite column (nondeterministic field)
- Wrong result: count(DISTINCT x COLLATE "C") with GROUP BY x on a nondeterministic collation
- BUG #19830: Mention that UNIQUE on a nondeterministic ICU collation treats ignorable characters as duplicates
- Re: Fix var_eq_const: sum selectivity of all matching MCV entries instead of stopping at first match
- BUG #19797: Wrong results: HAVING pushdown past GROUP BY on composite column with nondeterministic collation
- Check for non-deterministic FK collations before upgrade
- BUG #19633: Unexpected results of IN (subquery) with a non-deterministic collation
- BUG #19681: ILIKE rejected on nondeterministic collations while LIKE works
- Fix var_eq_const: sum selectivity of all matching MCV entries instead of stopping at first match
- BUG #19645: Partition key opclass bypasses nondeterministic collation check, wrong results
- BUG #19646: Unique index with explicit COLLATE bypasses nondeterministic collation rule
- Fix for fragile code in hashtext()
- [PATCH] Fix for bug #19474: LIKE fails to match literal backslashes with nondeterministic collations
- Fix HAVING-to-WHERE pushdown with mismatched operator families
- Test timings are increasing too fast for cfbot
- Yet another bug in nondeterministic LIKE
- BUG #19534: Qual pushdown across a window subquery is unsafe with nondeterministic partition collations
- Support LIKE with nondeterministic collations
- BUG #19474: LIKE with nondeterministic collations mis-handle literal backslashes in patterns containing escape
- Fix HAVING-to-WHERE pushdown with nondeterministic collations
- Wrong results with equality search using trigram index and non-deterministic collation
- Wrong results from inner-unique joins caused by collation mismatch
- BUG #19341: REPLACE() fails to match final character when using nondeterministic ICU collation
- comment in index_create "text_eq" should be "texteq"
- Support POSITION with nondeterministic collations
- Support regular expressions with nondeterministic collations
- altering a column's collation leaves an invalid foreign key
- UNION versus collations
- [17+] check after second call to pg_strnxfrm is too strict, relax it
- Explanations not clear
- BUG #17746: Partitioning by hash of a text depends on icu version when text collation is not deterministic
- hashing bpchar for nondeterministic collations is broken
- insensitive collations
- nondeterministic collations and statistics and pattern matching
- Explicit deterministic COLLATE fails with pattern matching operations on column with non-deterministic collation
- Nondeterministic collations vs. text_pattern_ops