Re: Slow performance with left outer join

Поиск
Список
Период
Сортировка
От Pavel Stehule
Тема Re: Slow performance with left outer join
Дата
Msg-id 162867790801211004q3b01f0a3hb97d162392ac037@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Slow performance with left outer join  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-performance
Hello

> >               Filter: ((COALESCE((at_type)::integer, 1) = 1) AND (COALESCE(at_language, 0::numeric) = 0::numeric))
>
> If this is slow, it must be that the scan of fpuarticletext actually
> returns many more rows than the single row the planner is expecting.
> The reason the estimate is off is probably that the planner cannot make
> any useful estimate about those COALESCE expressions.  Try rewriting
> them in the simpler forms
>
>         (at_type = 1 or at_type is null) AND
>         (at_language = 0 or at_language is null)
>

what about put this topic into FAQ.

Regards
Pavel Stehule

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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: Slow performance with left outer join
Следующее
От: Decibel!
Дата:
Сообщение: Re: strange pauses