Re: [SQL] quest:optimization with indexes

From: "Ross J(dot) Reedstrom" <reedstrm(at)wallace(dot)ece(dot)rice(dot)edu>
To: pgsql-sql(at)postgreSQL(dot)org
Cc: Clayton Cottingham <drfrog(at)smartt(dot)com>
Subject: Re: [SQL] quest:optimization with indexes
Date: 1999-08-11 14:12:57
Message-ID: 19990811091257.A2912@wallace.ece.rice.edu
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-sql

On Wed, Aug 11, 1999 at 04:30:13PM +0300, Herouth Maoz wrote:
> At 01:42 +0300 on 11/08/1999, Clayton Cottingham wrote:
> >
> > where/what rules should be followed for setting up a good indexing
> > scheme under pg?
>
<snipped Herouth's good summation of the rules of indices>

One thing to add: after adding your index, vacuum analyze you table, or else
the optimizer may thing you've only got a few rows in your table, and refuse
to use the indices, because it thinks sequential scans are relatively cheap.

Ross
--
Ross J. Reedstrom, Ph.D., <reedstrm(at)rice(dot)edu>
NSBRI Research Scientist/Programmer
Computer and Information Technology Institute
Rice University, 6100 S. Main St., Houston, TX 77005

In response to

Responses

Browse pgsql-sql by date

  From Date Subject
Next Message Clayton Cottingham 1999-08-11 17:43:30 Re: [SQL] quest:optimization with indexes
Previous Message Herouth Maoz 1999-08-11 13:30:13 Re: [SQL] quest:optimization with indexes