Re: Trigram (pg_trgm) GIN index not used

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Trigram (pg_trgm) GIN index not used
Дата
Msg-id 27614.1361464073@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Trigram (pg_trgm) GIN index not used  (Merlin Moncure <mmoncure@gmail.com>)
Список pgsql-general
Merlin Moncure <mmoncure@gmail.com> writes:
> On Thu, Feb 21, 2013 at 9:57 AM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
>> I wonder whether we really need that citext-specific operator at all
>> ... but in the meantime, if you need the column to be citext for some
>> other reason, I'd suggest making a gin index on raw_data::text and
>> then writing the query as raw_data::text ilike '%zagreb%'.

> hm, one more data point that citext implementation didn't succeed in
> terms of abstracting you from case sensitivity issues.

I think this is just a bug and not a fundamental design flaw: it looks
to me like simply removing the citext-specific declarations of the regex
operators would fix the problem (because then it'd fall back on the
standard operators with an implicit cast to text, and that would match
the index).  Might cause a problem though for anybody who's got those
operators embedded in views.

            regards, tom lane

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

Предыдущее
От: Merlin Moncure
Дата:
Сообщение: Re: Trigram (pg_trgm) GIN index not used
Следующее
От: "Sahagian, David"
Дата:
Сообщение: FATAL logged when starting