Re: The science of optimization in practical terms?

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: The science of optimization in practical terms?
Дата
Msg-id 27636.1235000228@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: The science of optimization in practical terms?  (Simon Riggs <simon@2ndQuadrant.com>)
Список pgsql-hackers
Simon Riggs <simon@2ndQuadrant.com> writes:
> On Wed, 2009-02-18 at 15:32 -0500, Tom Lane wrote:
>> An idea that I think has been mentioned before is to try to identify
>> cases where we can *prove* there is at most one row emitted by a
>> sub-path (eg, because of a unique index, DISTINCT subplan, etc).

> Proof seems best way forward. IIRC the reason we didn't do this before
> HOT is that unique index scans did often return many more than one row.

But those extra tuples didn't make it up to the point of the join, so
they weren't really a problem for nestloop speed.  IMO the reason this
hasn't been done to date is that until recently we didn't have any
mechanism to ensure a plan got invalidated if some constraint it was
depending on (like uniqueness) went away.  Now we do, so it would be
safe to rely on the constraint for proof purposes.
        regards, tom lane


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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: Re: [COMMITTERS] pgsql: Start background writer during archive recovery.
Следующее
От: Adriano Lange
Дата:
Сообщение: Re: graph representation of data structures in optimizer