Re: left outer join terrible slow compared to inner join - Mailing list pgsql-general

From Tom Lane
Subject Re: left outer join terrible slow compared to inner join
Date
Msg-id 11780.1062098800@sss.pgh.pa.us
Whole thread Raw
In response to Re: left outer join terrible slow compared to inner join  (Thomas Beutin <tyrone@laokoon.IN-Berlin.DE>)
List pgsql-general
Thomas Beutin <tyrone@laokoon.IN-Berlin.DE> writes:
>> Hmm, I don't understand why ot_kat_prod is being treated as a subquery
>> here.  It isn't a view or something is it?

> Sorry, You're correct, actually this is a view of an other table called
> o_kat_prod defined as
> SELECT * FROM o_kat_prod;
> but supposed to be in my next step something like
> SELECT * FROM o_kat_prod WHERE <a_single_field> IS NOT NULL;

Still curious, since I'd expect 7.2 to flatten a simple view into the
upper query.

> Do i've any chance to get the same performance on the view?

Try 7.3, it may be better.  Or consider 7.4 beta.

            regards, tom lane

pgsql-general by date:

Previous
From: Thomas Beutin
Date:
Subject: Re: left outer join terrible slow compared to inner join
Next
From: Jan Wieck
Date:
Subject: Re: Replication Ideas