From: Scott Marlowe <scott.marlowe@gmail.com>
To: lionel duboeuf <lionel.duboeuf@boozter.com>
Cc: pgsql-performance@postgresql.org
Subject: Re: Almost infinite query -> Different Query Plan when changing where clause value
Date: Mon, 15 Feb 2010 10:24:27 -0700
Message-ID: <dcc563d11002150924r2b6afb9dg685b7af94fa06798@mail.gmail.com> (raw)
In-Reply-To: <4B791971.6020804@boozter.com>
References: <4B755913.7090004@boozter.com>
<4B7519C5020000250002F242@gw.wicourts.gov>
<4B75BADE.9030906@boozter.com>
<4B756CE5020000250002F27C@gw.wicourts.gov>
<4B791971.6020804@boozter.com>
On Mon, Feb 15, 2010 at 2:52 AM, lionel duboeuf
<lionel.duboeuf@boozter.com> wrote:
> See as attachment the "correct" query plan for an other 'user'.
> I confirm by executing manual "VACUUM ANALYZE" that the problem is solved.
> But what i don't understand is that i would expect autovacuum to do the job.
There are two operations here. Vacuum, which reclaims lost space, and
analyze which analyzes your data and stores histograms to be used when
building queries, to determine how many rows are likely to be returned
by each part of the plan.
The autovac daemon runs both vacuums and analyzes, often independently
of each other, when needed, based on threshold settings. By running
autovac your db would get analyzed when necessary and would then have
up to date statistics when queries were run after that.
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-performance@postgresql.org
Cc: scott.marlowe@gmail.com, lionel.duboeuf@boozter.com
Subject: Re: Almost infinite query -> Different Query Plan when changing where clause value
In-Reply-To: <dcc563d11002150924r2b6afb9dg685b7af94fa06798@mail.gmail.com>
References: <4B755913.7090004@boozter.com> <4B7519C5020000250002F242@gw.wicourts.gov> <4B75BADE.9030906@boozter.com> <4B756CE5020000250002F27C@gw.wicourts.gov> <4B791971.6020804@boozter.com> <dcc563d11002150924r2b6afb9dg685b7af94fa06798@mail.gmail.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox