Re: - Slow Query

Поиск
Список
Период
Сортировка
От Scott Marlowe
Тема Re: - Slow Query
Дата
Msg-id dcc563d10907011042o7936fe16q6b04c4d7369bb472@mail.gmail.com
обсуждение исходный текст
Ответ на Re: - Slow Query  (Rui Carvalho <rui.hmcarvalho@gmail.com>)
Ответы Re: - Slow Query
Список pgsql-performance
On Wed, Jul 1, 2009 at 11:37 AM, Rui Carvalho<rui.hmcarvalho@gmail.com> wrote:
> hum thanks a lot for the quick answer,
>
> if is not abuse of your patience
>
> what is the best alternative to the LEFT OUTER JOINS?

Hard to say.  Generally, when you really do need a left, right, or
full outer join, you need it, and there's not a lot of alternatives.
Sometimes putting a where clause portion into the on clause helps.
like:

select * from a left join b on (a.id=b.id) where a.somefield=2

might run faster with

select * from a left join b on (a.id=bid. and a.somefield=2);

but it's hard to say.  I'd definitely post it to the list and see who
knows what.

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

Предыдущее
От: Rui Carvalho
Дата:
Сообщение: Re: - Slow Query
Следующее
От: Tom Lane
Дата:
Сообщение: Re: - Slow Query