Skip site navigation (1) Skip section navigation (2)

Re: SQL stupid query plan... terrible performance !

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Klint Gore <kg(at)kgb(dot)une(dot)edu(dot)au>
Cc: pgsql-performance(at)postgresql(dot)org
Subject: Re: SQL stupid query plan... terrible performance !
Date: 2004-06-28 05:48:43
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-performance
Klint Gore <kg(at)kgb(dot)une(dot)edu(dot)au> writes:
> On Sun, 27 Jun 2004 23:29:46 -0400, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
>> [yawn...]  Cast the constants to bigint.  See previous discussions.

> Would there be any way of adding some sort of indicator to the plan as
> to why sequential was chosen?

Not really ... the plan that's presented is the one that looked the
cheapest out of the feasible plans.  How are you going to identify a
single reason as to why any other plan was not generated or lost out
on a cost-estimate basis?  Humans might be able to do so (note that
the above quote is an off-the-cuff estimate, not something I'd care
to defend rigorously) but I don't think software can do it.

FWIW, the particular problem here should be fixed in 7.5.

			regards, tom lane

In response to


pgsql-performance by date

Next:From: Richard HuxtonDate: 2004-06-28 09:14:11
Subject: Re: Query performance
Previous:From: Klint GoreDate: 2004-06-28 05:29:57
Subject: Re: SQL stupid query plan... terrible performance !

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group