Re: 8.4.4, 9.0, and 9.1 Planner Differences

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Anthony Presley <anthony(at)resolution(dot)com>
Cc: pgsql-performance <pgsql-performance(at)postgresql(dot)org>, Erik Van Gilder <evg(at)resolution(dot)com>
Subject: Re: 8.4.4, 9.0, and 9.1 Planner Differences
Date: 2011-10-23 02:31:59
Message-ID: 20459.1319337119@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

Anthony Presley <anthony(at)resolution(dot)com> writes:
> I have tried setting the statistics on employee.user_id to be 100 and 1000,
> and the rest are the default (100).

> I've run both an "ANALYZE" and a "VACUUM ANALYZE" on the production system -
> both "generally", and on each of the above tables (employee, app_user,
> location, preference).

> Here's an updated explain of the most recent attempt. About 5 minutes after
> I analyzed them:
> http://explain.depesz.com/s/G32

Looks like the biggest estimation errors are on the location_id joins.
Maybe you should be cranking up the stats targets on those columns.

regards, tom lane

In response to

Browse pgsql-performance by date

  From Date Subject
Next Message Robins Tharakan 2011-10-23 10:38:19 Re: explain workload
Previous Message Stefan Keller 2011-10-22 23:33:53 hstore query: Any better idea than adding more memory?