Re: seq scan instead of index scan

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: seq scan instead of index scan
Дата
Msg-id 29683.1261117631@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: seq scan instead of index scan  (Greg Smith <greg@2ndquadrant.com>)
Список pgsql-performance
Greg Smith <greg@2ndquadrant.com> writes:
> Karl Larsson wrote:
>> When I make a subquery Postgres don't care about my indexes and makes
>> a seq scan instead of a index scan. Why?

> Data set is just too small for it to matter.  Watch what happens if I
> continue from what you posted with much bigger tables:
> ...
> There's the index scan on both tables that you were expecting.

And if you go much past that, it's likely to switch *away* from
indexscans again (eg, to a hash join, which has no use for ordered
input).  This is not wrong.  Indexes have their place but they are not
the solution for every query.

            regards, tom lane

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

Предыдущее
От: Craig Ringer
Дата:
Сообщение: Re: Automatic optimization of IN clauses via INNER JOIN
Следующее
От: Sigurgeir Gunnarsson
Дата:
Сообщение: Re: Issues with \copy from file