Re: Queries not using Index - Mailing list pgsql-sql

From Christopher Kings-Lynne
Subject Re: Queries not using Index
Date
Msg-id GNELIHDDFBOCMGBFGEFOCEEPCDAA.chriskl@familyhealth.com.au
Whole thread Raw
In response to Re: Queries not using Index  (Daryl Herzmann <akrherz@iastate.edu>)
Responses Re: Queries not using Index  (Daryl Herzmann <akrherz@iastate.edu>)
List pgsql-sql
> I inserted the data via 30 "COPY t2002_06 from stdin" (one per
> day)  So it
> was grouped by station and then day for each insert.  (My script dumped
> the data from each station for the day and then repeated for each station
> and then finally dumped the entire day into the DB.  Are you saying that
> this process has tricked pgsql into not believing it needs to use an
> INDEX?  Sorry for my ignorance here.  I have done similar processes with
> PG7.1.2 and it seemed to use the INDEX.
>
> In fact, I just repeated the dumping scripts on a machine with 7.1.2 and
> the "explain select" reports to be using the Index Scan.  Hmmmm

You _have_ actually run ANALYZE on the table, right?

Chris



pgsql-sql by date:

Previous
From: Daryl Herzmann
Date:
Subject: Re: Queries not using Index
Next
From: Daryl Herzmann
Date:
Subject: Re: Queries not using Index