Re: Single table forcing sequential scans on query plans - Mailing list pgsql-hackers

From Alvaro Herrera
Subject Re: Single table forcing sequential scans on query plans
Date
Msg-id 20080317133743.GG6083@alvh.no-ip.org
Whole thread Raw
In response to Re: Single table forcing sequential scans on query plans  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
Tom Lane wrote:

> Another possibility (though not a back-patchable solution) is that
> we could just dispense with the heuristic size estimate and trust a
> zero-sized table to stay zero-sized.  This would be relying on the
> assumption that autovacuum will kick in and update the stats, leading
> to invalidation of any existing plans that assume the table is small.
> I don't feel very comfortable about that though --- throwing a few
> hundred tuples into a table might not be enough to draw autovacuum's
> attention, but it could surely be enough to create a performance
> disaster for nestloop plans.

FWIW autovacuum fires an analyze with the 51st tuple inserted on a
table on 8.3's default configuration.

-- 
Alvaro Herrera                                http://www.CommandPrompt.com/
The PostgreSQL Company - Command Prompt, Inc.


pgsql-hackers by date:

Previous
From: Alvaro Herrera
Date:
Subject: Re: [COMMITTERS] pgsql: Some cleanups of enum-guc code, per comments from Tom.
Next
From: Alvaro Herrera
Date:
Subject: Re: [0/4] Proposal of SE-PostgreSQL patches