Re: Seq Scans when index expected to be used

From: Stephan Szabo <sszabo(at)megazone(dot)bigpanda(dot)com>
To: ow <oneway_111(at)yahoo(dot)com>
Cc: pgsql-sql(at)postgresql(dot)org
Subject: Re: Seq Scans when index expected to be used
Date: 2003-11-29 17:37:12
Message-ID: 20031129093428.R75231@megazone.bigpanda.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql


On Sat, 29 Nov 2003, ow wrote:

> Am trying to find duplicate values in a large table (about 80M records).
> Somehow, none of the two (2) queries (see below) is using the index "I_bca"
> that, I believe, should've been used.

As a side note, to help determine if it should be used, you probably want
explain analyze not just explain. In general the index is only going to
help you if the sort is very expensive, not for the initial scan (where
the seq scan is generally faster).

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message greg 2003-11-29 17:51:10 Re: Equivalent of Reverse() functions
Previous Message Joe Conway 2003-11-29 17:26:43 Re: Seq Scans when index expected to be used