Re: insensitive collations
Peter Eisentraut <peter.eisentraut@2ndquadrant.com>
From: Peter Eisentraut <peter.eisentraut@2ndquadrant.com>
To: Daniel Verite <daniel@manitou-mail.org>
Cc: pgsql-hackers <pgsql-hackers@postgresql.org>
Date: 2019-02-06T22:46:29Z
Lists: pgsql-hackers
Attachments
On 30/01/2019 16:30, Daniel Verite wrote: > Peter Eisentraut wrote: > >> Another patch. Another patch, with expanded documentation, more tests, and some code cleanup. > > + <literal>ks</literal> key), in order for such such collations to act in > a > > s/such such/such/ fixed > > + <para> > + The pattern matching operators of all three kinds do not support > + nondeterministic collations. If required, apply a different collation > to > + the expression to work around this limitation. > + </para> > > It's an important point of comparison between CI collations and > contrib/citext, since the latter diverts a bunch of functions/operators > to make them do case-insensitive pattern matching. > The doc for citext explains the rationale for using it versus text, > maybe it would need now to be expanded a bit with pros/cons of > choosing citext versus non-deterministic collations. possibly addressed by the expanded documentation > The current patch doesn't alter a few string functions that could > potentially implement collation-aware string search, such as > replace(), strpos(), starts_with(). > ISTM that we should not let these functions ignore the collation: they > ought to error out until we get their implementation to use the ICU > collation-aware string search. I have addressed that. Many of these end up at the same one or two low-level C function, so the checking just happens there. -- Peter Eisentraut http://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
Commits
-
Collations with nondeterministic comparison
- 5e1963fb764e 12.0 landed
-
Add support for collation attributes on older ICU versions
- b8f9a2a69a27 12.0 landed
-
Make type "name" collation-aware.
- 586b98fdf1aa 12.0 cited
-
Make collation-aware system catalog columns use "C" collation.
- 6b0faf723647 12.0 cited
-
Adjust string comparison so that only bitwise-equal strings are considered
- 656beff59033 8.2.0 cited