Re: 8.4.7, incorrect estimate

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Kevin Grittner" <Kevin(dot)Grittner(at)wicourts(dot)gov>
Cc: "Wayne Conrad" <wayne(at)databill(dot)com>, pgsql-performance(at)postgresql(dot)org
Subject: Re: 8.4.7, incorrect estimate
Date: 2011-04-29 20:58:21
Message-ID: 13918.1304110701@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

"Kevin Grittner" <Kevin(dot)Grittner(at)wicourts(dot)gov> writes:
> Also, make sure that you run ANALYZE against your temp table right
> before running your query.

Yeah. It's fairly hard to credit that temp_document_ids has any stats
given the way-off estimates for it. Keep in mind that autovacuum
can't help you on temp tables: since only your own session can
access a temp table, you have to ANALYZE it explicitly if you need
the planner to have decent stats about it.

regards, tom lane

In response to

Browse pgsql-performance by date

  From Date Subject
Next Message Greg Smith 2011-04-29 21:37:39 Re: Performance
Previous Message James Mansion 2011-04-29 20:27:21 Re: Performance