Re: Timestamps and performances problems

From: "Dan Langille" <dan(at)langille(dot)org>
To: "Gaetano Mendola" <mendola(at)bigfoot(dot)com>
Cc: pgsql-admin(at)postgresql(dot)org
Subject: Re: Timestamps and performances problems
Date: 2002-04-10 13:06:55
Message-ID: 20020410130743.C869D3F30@bast.unixathome.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

On 10 Apr 2002 at 11:51, Gaetano Mendola wrote:

> "Jean-Christophe ARNU (JX)" <jc(dot)arnu(at)free(dot)fr> wrote:
> > Hello all.
> > I've a performance problem on specific requests :
> >
> > When I use timestamps + interval in where clauses, query performance is
> > slowed down by a factor of 20 or 30!!!! For exemple :
> > select timestamp,value
> > from measure
> > where timestamp<now() and timestamp>(now() - '1 hour'::interval)

Try where timestamp<now() and timestamp>(now() - '1
hour'::interval)::timestemp.

--
Dan Langille
The FreeBSD Diary - http://freebsddiary.org/ - practical examples

In response to

Responses

Browse pgsql-admin by date

  From Date Subject
Next Message Jean-Christophe ARNU (JX) 2002-04-10 14:44:25 Re: Timestamps and performances problems
Previous Message Raphael Bauduin 2002-04-10 13:00:46 performance "tests"