Re: SOLVED - RE: Poor performance using CTE

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: SOLVED - RE: Poor performance using CTE
Дата
Msg-id 20462.1352910543@sss.pgh.pa.us
обсуждение исходный текст
Ответ на SOLVED - RE: Poor performance using CTE  (David Greco <David_Greco@harte-hanks.com>)
Ответы Re: SOLVED - RE: Poor performance using CTE
Список pgsql-performance
David Greco <David_Greco@harte-hanks.com> writes:
> Thanks, that did the trick. Though I'm still not clear as to why.

PG treats WITH as an optimization fence --- the WITH query will be
executed pretty much as-is.  It may be that Oracle flattens the query
somehow; though if you're using black-box functions in both cases,
it's not obvious where the optimizer could get any purchase that way.

            regards, tom lane


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

Предыдущее
От: David Greco
Дата:
Сообщение: SOLVED - RE: Poor performance using CTE
Следующее
От: Jeff Janes
Дата:
Сообщение: Re: postgres 8.4, COPY, and high concurrency