Re: Index Scans become Seq Scans after VACUUM ANALYSE
mlw <markw@mohawksoft.com>
From: mlw <markw@mohawksoft.com>
To: Thomas Lockhart <thomas@fourpalms.org>
Cc: Tom Lane <tgl@sss.pgh.pa.us>, Bruce Momjian <pgman@candle.pha.pa.us>, Louis-David Mitterrand <vindex@apartia.org>, pgsql-hackers@postgresql.org
Date: 2002-04-17T14:31:21Z
Lists: pgsql-hackers
Thomas Lockhart wrote: > Systems which have optimizing planners can *never* be guaranteed to > generate the actual lowest-cost query plan. Any impression that Oracle, > for example, actually does do that may come from a lack of visibility > into the process, and a lack of forum for discussing these edge cases. And here in lies the crux of the problem. It isn't a purely logical/numerical formula. It is a probability estimate, nothing more. Currently, the statistics are used to calculate a probable best query, not a guaranteed best query. The presence of an index should be factored into the probability of a best query, should it not?