Re: indexing timestamp fields

From: Bruno Wolff III <bruno(at)wolff(dot)to>
To: teknokrat <teknokrat(at)yahoo(dot)com>
Cc: pgsql-sql(at)postgresql(dot)org
Subject: Re: indexing timestamp fields
Date: 2003-10-16 16:56:29
Message-ID: 20031016165629.GA28009@wolff.to
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

On Wed, Oct 15, 2003 at 21:25:17 +0100,
teknokrat <teknokrat(at)yahoo(dot)com> wrote:
>
> I have a lot of queries of the " where timestamp < some date " type and
> was wondering if an index would improve performance. None of the
> timestamps are null and they are always populated

Unless that query returns only a small fraction of the table (which would
be unusual for a before some date restriction) or you order by the date,
an index probably won't help.

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message Steve Crawford 2003-10-16 17:35:35 Re: Calc
Previous Message Tom Lane 2003-10-16 14:43:19 Re: Alias-Error