Re: Index Scans become Seq Scans after VACUUM ANALYSE
Hannu Krosing <hannu@krosing.net>
From: Hannu Krosing <hannu@krosing.net>
To: mlw <markw@mohawksoft.com>
Cc: Christopher Kings-Lynne <chriskl@familyhealth.com.au>, Bruce Momjian <pgman@candle.pha.pa.us>, Tom Lane <tgl@sss.pgh.pa.us>, Louis-David Mitterrand <vindex@apartia.org>, pgsql-hackers@postgresql.org
Date: 2002-04-17T06:36:09Z
Lists: pgsql-hackers
On Wed, 2002-04-17 at 11:00, mlw wrote: > > Here is the problem, in a single paragraph. > > If the DBA notices that there is a problem with a query, he adds an index, he > notices that there is no difference, then he notices that PostgreSQL is not > using his index. First and foremost he gets mad at PostgreSQL for not using his > index. Perhaps a notice from backend: NOTICE: I see the DBA has created a useless index ... ;) Or would this make the DBA even madder ;) ;) > If PostgreSQL decided to use an index which increases execution time, > the DBA would delete the index. If PostgreSQL does not use an index, he has to > modify the posgresql.conf file, Or just do set enable_seqscan to off; > which disallows PostgreSQL from using an index when it would be a clear loser. > > My assertion is this: "If a DBA creates an index, he has a basis for his > actions." The basis can be that "his boss told him to" ? ------------------ Hannu