Re: INNER JOIN ON vs ','+WHERE

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Thalis A(dot) Kalfigopoulos" <thalis(at)cs(dot)pitt(dot)edu>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: INNER JOIN ON vs ','+WHERE
Date: 2001-06-25 17:52:48
Message-ID: 16712.993491568@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

"Thalis A. Kalfigopoulos" <thalis(at)cs(dot)pitt(dot)edu> writes:
> I noticed that doing a join with the INNER JOIN ON... syntax gives a different execution plan (for complex queries at least) than when using the ',' syntax with the join conditions in the WHERE clause. Actually the latter proved more efficient :-/
> I assume/guess/speculate that the optimizer gets more freedom in the order it'll perform the join when all conditions are just thrown in the WHERE clause whereas the former case forces it to follow the user provided join order?

http://www.ca.postgresql.org/users-lounge/docs/7.1/postgres/explicit-joins.html

regards, tom lane

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Trond Eivind =?iso-8859-1?q?Glomsr=F8d?= 2001-06-25 18:08:54 Re: Red Hat to support PostgreSQL
Previous Message Thalis A. Kalfigopoulos 2001-06-25 17:38:46 Re: Red Hat to support PostgreSQL