Re: Performance Optimization for Dummies 2 - the SQL - Mailing list pgsql-performance

From Jim C. Nasby
Subject Re: Performance Optimization for Dummies 2 - the SQL
Date
Msg-id 20061008203450.GK72517@nasby.net
Whole thread Raw
In response to Re: Performance Optimization for Dummies 2 - the SQL  ("Merlin Moncure" <mmoncure@gmail.com>)
Responses Re: Performance Optimization for Dummies 2 - the SQL  ("Merlin Moncure" <mmoncure@gmail.com>)
List pgsql-performance
On Thu, Oct 05, 2006 at 09:30:45AM -0400, Merlin Moncure wrote:
> I personally only use explicit joins when doing outer joins and even
> them push them out as far as possible.

I used to be like that too, until I actually started using join syntax.
I now find it's *way* easier to identify what the join conditions are,
and to seperate them from the rest of the where clause. It also makes it
pretty much impossible to mess up a join clause and get a cartesian
product.

If you are going to put the join clauses in the WHERE clause, at least
put a space between the join stuff and the rest of the WHERE clause.

In any case, this is nothing but a matter of taste in this case, unless
you set join_collapse_limit to less than 3 (or maybe 4).
--
Jim Nasby                                            jim@nasby.net
EnterpriseDB      http://enterprisedb.com      512.569.9461 (cell)

pgsql-performance by date:

Previous
From: "Craig A. James"
Date:
Subject: Re: Simple join optimized badly?
Next
From: "Jim C. Nasby"
Date:
Subject: Re: Performance Optimization for Dummies 2 - the SQL