From: Tom Lane <tgl@sss.pgh.pa.us>
To: Simon Riggs <simon@2ndquadrant.com>
Cc: pgsql-performance <pgsql-performance@postgresql.org>
Subject: Re: Outer joins and equivalence
Date: Tue, 27 May 2008 17:43:12 -0400
Message-ID: <14085.1211924592@sss.pgh.pa.us> (raw)
In-Reply-To: <1211918358.4489.257.camel@ebony.site>
References: <1211918358.4489.257.camel@ebony.site>
Simon Riggs <simon@2ndquadrant.com> writes:
> I have a complex query where making a small change to the SQL increases
> run-time by > 1000 times.
> The first SQL statement is of the form
> A JOIN B ON (a.id = b.id) LEFT JOIN C ON (a.id = c.id)
> and the second is like this
> A JOIN B ON (a.id = b.id) LEFT JOIN C ON (b.id = c.id)
> the only difference is the substitution of a -> b
Please provide an actual test case.
regards, tom lane
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-performance@postgresql.org
Cc: tgl@sss.pgh.pa.us, simon@2ndquadrant.com
Subject: Re: Outer joins and equivalence
In-Reply-To: <14085.1211924592@sss.pgh.pa.us>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox