Re: LIMIT confuses the planner

Поиск
Список
Период
Сортировка
От Kouber Saparev
Тема Re: LIMIT confuses the planner
Дата
Msg-id 49A2EE86.5070805@saparev.com
обсуждение исходный текст
Ответ на Re: LIMIT confuses the planner  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-performance
Tom Lane wrote:
> Robert Haas <robertmhaas@gmail.com> writes:
>> If you left seq_page_cost (which isn't mentioned here) at the default
>> value but reduced random_page_cost to 0.1, then you have
>> random_page_cost < seq_page_cost.  That's probably Bad.
>
> ... well, it's certainly going to push the planner to believe indexscans
> are cheaper than sorts no matter what.
>
> The previously noted rowcount estimation problem might be a bigger issue
> in this particular case, but I agree this is a Bad Idea.

So I've set it wrong, I guess. :-)

Now I put it to:

seq_page_cost = 1
random_page_cost = 2

Regards,
--
Kouber Saparev
http://kouber.saparev.com

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

Предыдущее
От: Sergio Lopez
Дата:
Сообщение: Re: Benchmark comparing PostgreSQL, MySQL and Oracle
Следующее
От: "Ross J. Reedstrom"
Дата:
Сообщение: Re: TCP network cost