From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | han(dot)holl(at)informationslogik(dot)nl |
Cc: | pgsql-general(at)postgresql(dot)org |
Subject: | Re: How to inject knowledge into a Postgres database |
Date: | 2005-10-13 14:06:20 |
Message-ID: | 21051.1129212380@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
han(dot)holl(at)informationslogik(dot)nl writes:
> I've increased the statistics to 1000, and only occasionally, because of the
> very uneven distribution of surnames, the planner does the wrong thing.
> I've tried to set an even higher limit, but 1000 seems to be the maximum.
> Is this hardcoded, or can I set a higher maximum somewhere ?
You'd have to change the source code, but it's a simple tweak in the
ALTER SET STATISTICS code.
> If the only penalty is slower analyzing, I don't care: we analyze at night
> when these system are idle.
You'd be wrong about that --- the planner operations that use the data
would necessarily be slower, too. I don't have any concrete information
about how much slower, but I'd be hesitant to raise the figure much
beyond 1000 ...
However, if you can show you have a real-world case that benefits, I'd
be willing to think about raising the wired-in limit to 10000 or so.
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Richard Huxton | 2005-10-13 14:47:04 | Re: slow insert query. |
Previous Message | H Hale | 2005-10-13 13:39:45 | binary timestamp conversion |