Re: Very poor estimates from planner - Mailing list pgsql-hackers

From scott.marlowe
Subject Re: Very poor estimates from planner
Date
Msg-id Pine.LNX.4.33.0311051554110.11025-100000@css120.ihs.com
Whole thread Raw
In response to Very poor estimates from planner  (Rod Taylor <rbt@rbt.ca>)
Responses Re: Very poor estimates from planner  (Rod Taylor <rbt@rbt.ca>)
List pgsql-hackers
On Wed, 5 Nov 2003, Rod Taylor wrote:

> Since this is a large query, attachments for the explains / query.
> 
> Configuration:
>         dev_iqdb=# select version();
>                                         version
>         ------------------------------------------------------------------------
>          PostgreSQL 7.4beta1 on i386-portbld-freebsd4.7, compiled by GCC
>         2.95.4
>         (1 row)
> 
>         SET default_statistics_target = 1000;
>         ANALYZE;
>         set from_collapse_limit = 100;
>         set join_collapse_limit = 20;

I'm not sure if that will actually change the default_statistics_target of 
the tables you're analyzing, I think it will only apply to newly created 
tables.  

I believe you have to alter table alter column set statistics 1000 for 
each column you want a statistic of 1000.  You might wanna try starting 
with 50 or 100 and see if that works first.



pgsql-hackers by date:

Previous
From: Neil Conway
Date:
Subject: Re: [pgsql-www] Changes to Contributor List
Next
From: Peter Eisentraut
Date:
Subject: Re: Changes to Contributor List