Re: Encouraging multi-table join order

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Dan Harris <fbsd(at)drivefaster(dot)net>
Cc: PostgreSQL Performance <pgsql-performance(at)postgresql(dot)org>
Subject: Re: Encouraging multi-table join order
Date: 2006-04-11 21:29:23
Message-ID: 11015.1144790963@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

Dan Harris <fbsd(at)drivefaster(dot)net> writes:
> I wonder why the estimates were so far off the first time? This table
> has been ANALYZED regularly ever since creation.

Probably just that you need a bigger sample size for such a large table.
We've been arguing ever since 7.2 about what the default statistics
target ought to be --- a lot of people think 10 is too small. (It could
also be that the fixed 300X multiplier ought to depend on table size
instead. The math that told us 300X was OK was really about getting the
histogram right, not about whether the most-common-values stats would be
any good.)

regards, tom lane

In response to

Browse pgsql-performance by date

  From Date Subject
Next Message Harry Hehl 2006-04-11 21:56:38 Re: Sequencial scan instead of using index
Previous Message Dan Harris 2006-04-11 21:21:48 Re: Encouraging multi-table join order