Re: unexpected query failure: ERROR: GIN indexes do not support whole-index scans

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: unexpected query failure: ERROR: GIN indexes do not support whole-index scans
Дата
Msg-id 27387.1287442870@sss.pgh.pa.us
обсуждение исходный текст
Ответ на unexpected query failure: ERROR: GIN indexes do not support whole-index scans  (Jon Nelson <jnelson+pgsql@jamponi.net>)
Ответы Re: unexpected query failure: ERROR: GIN indexes do not support whole-index scans  (Jon Nelson <jnelson+pgsql@jamponi.net>)
Список pgsql-performance
Jon Nelson <jnelson+pgsql@jamponi.net> writes:
> CREATE INDEX foo_idx ON t USING GIN (alternatecodes) WHERE
> alternatecodes IS NOT NULL;
> SELECT * FROM t WHERE alternatecodes IS NOT NULL;
> ERROR:  GIN indexes do not support whole-index scans

Yep, this is a known issue.  It's going to take major surgery on GIN to
fix it, so don't hold your breath.  In the particular case, what good do
you think the WHERE clause is doing anyway?  GIN won't index nulls at
all ... which indeed is an aspect of the underlying issue --- see recent
discussions, eg here:
http://archives.postgresql.org/pgsql-hackers/2010-10/msg00521.php

            regards, tom lane

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

Предыдущее
От: Jon Nelson
Дата:
Сообщение: unexpected query failure: ERROR: GIN indexes do not support whole-index scans
Следующее
От: Scott Carey
Дата:
Сообщение: HashJoin order, hash the large or small table? Postgres likes to hash the big one, why?