From: | Kevin Grittner <kgrittn(at)ymail(dot)com> |
---|---|
To: | Ben <midfield(at)gmail(dot)com>, bricklen <bricklen(at)gmail(dot)com> |
Cc: | "pgsql-performance(at)postgresql(dot)org list" <pgsql-performance(at)postgresql(dot)org> |
Subject: | Re: incorrect row estimates for primary key join |
Date: | 2013-06-25 13:20:29 |
Message-ID: | 1372166429.65996.YahooMailNeo@web162901.mail.bf1.yahoo.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-performance |
Ben <midfield(at)gmail(dot)com> wrote:
> PostgreSQL 9.1.1 on x86_64-suse-linux-gnu, compiled by gcc (SUSE Linux) 4.6.2, 64-bit
Consider applying the latest bug fixes for 9.1 -- which would leave
you showing 9.1.9.
http://www.postgresql.org/support/versioning/
> default_statistics_target | 50 | configuration file
Why did you change this from the default of 100?
> effective_cache_size | 5632MB | configuration file
How much RAM is on this machine? What else is running on it?
(Normally people set this to 50% to 75% of total RAM. Lower values
discourage index usage in queries like your example.)
Do you get a different plan if you set cpu_tuple_cost = 0.03? How
about 0.05? You can set this just for a single connection and run
explain on the query to do a quick check.
--
Kevin Grittner
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company
From | Date | Subject | |
---|---|---|---|
Next Message | Julien Cigar | 2013-06-25 14:43:56 | Re: incorrect row estimates for primary key join |
Previous Message | Emrah Mehmedov | 2013-06-25 10:15:00 | Re: PHP Postgres query slower then PgAdmin |