Re: Slow Query- Bad Row Estimate

From: Josh Berkus <josh(at)agliodbs(dot)com>
To: pgsql-performance(at)postgresql(dot)org
Subject: Re: Slow Query- Bad Row Estimate
Date: 2010-10-29 21:09:37
Message-ID: 4CCB3811.80900@agliodbs.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

On 10/29/10 1:54 PM, Ozer, Pam wrote:
> " -> Index Scan using dealergroupgeocache_i01 on
> dealergroupgeocache (cost=0.00..5719.56 rows=9055 width=10) (actual
> time=0.015..87.689 rows=163491 loops=1)"

This appears to be your problem here.

a) when was dealergroupgeocache last ANALYZED?

b) try increasing the stats_target on dealergroupid and regionid, to say
500 and re-analyzing.

--
-- Josh Berkus
PostgreSQL Experts Inc.
http://www.pgexperts.com

In response to

Responses

Browse pgsql-performance by date

  From Date Subject
Next Message david 2010-10-29 21:14:26 Re: BBU Cache vs. spindles
Previous Message Ozer, Pam 2010-10-29 20:54:04 Slow Query- Bad Row Estimate