Re: Support LIKE with nondeterministic collations

Поиск
Список
Период
Сортировка
От Daniel Verite
Тема Re: Support LIKE with nondeterministic collations
Дата
Msg-id 9364e6e6-9cc2-4eb1-91b1-dc4c780af597@manitou-mail.org
обсуждение исходный текст
Ответ на Re: Support LIKE with nondeterministic collations  (Jeff Davis <pgsql@j-davis.com>)
Список pgsql-hackers
    Jeff Davis wrote:

> >   col LIKE 'smith%' collate "nd"
> >
> > is equivalent to:
> >
> >   col >= 'smith' collate "nd" AND col < U&'smith\ffff' collate "nd"
>
> That logic seems to assume something about the collation. If you have a
> collation that orders strings by their sha256 hash, that would entirely
> break the connection between prefixes and ranges, and it wouldn't work.

Indeed I would not trust this trick to work outside of ICU collations.


Best regards,
--
Daniel Vérité
https://postgresql.verite.pro/
Twitter: @DanielVerite



В списке pgsql-hackers по дате отправления: