Re: Why does query planner choose slower BitmapAnd ?

Поиск
Список
Период
Сортировка
От Stephen Frost
Тема Re: Why does query planner choose slower BitmapAnd ?
Дата
Msg-id 20160222193325.GF13092@tamriel.snowman.net
обсуждение исходный текст
Ответ на Re: Why does query planner choose slower BitmapAnd ?  (Seamus Abshere <seamus@abshere.net>)
Список pgsql-general
* Seamus Abshere (seamus@abshere.net) wrote:
> Is there any other way to differentiate the 2 index scans? FWIW, 10% of
> houses are phoneable, 0.2% are in the city. (Maybe I'm just supposed to
> drop the index like Tom said.)

Have to admit that I continue to be interested in this as it might
relate to the somewhat similar (or, at least, seems to be, to me) case
that I ran into before.

What might be interesting would be to see a run with:

explain (analyze, verbose, buffers) select ...

for both of the original queries.  It'd also be nice to know what the
size is of each of the indexes involved.

Last, but perhaps not least, have you considered using a partial index
and only indexing where phoneable is actually true?  That would remove
the need to update the index for the case where phoneable is false and
would make the index smaller.  I don't know that it'd really change
what's going on here, though if it did, that would be interesting too.

Thanks!

Stephen

Вложения

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

Предыдущее
От: "Joshua D. Drake"
Дата:
Сообщение: Re: decoding BLOB's
Следующее
От: John R Pierce
Дата:
Сообщение: Re: decoding BLOB's