Re: Query tuning - Mailing list pgsql-performance

From Grzegorz Jaśkiewicz
Subject Re: Query tuning
Date
Msg-id 2f4958ff0908190938l683b2ed4w94b6d36361307e35@mail.gmail.com
Whole thread Raw
In response to Query tuning  (Kevin Kempter <kevink@consistentstate.com>)
Responses Re: Query tuning
List pgsql-performance
that seems to be the killer:

and time >= extract ('epoch' from timestamp '2009-08-12')
and time < extract ('epoch' from timestamp '2009-08-13' )

You probably need an index on time/epoch:

CREATE INDEX foo ON table(extract ('epoch' from timestamp time );

or something like that, vacuum analyze and retry.

pgsql-performance by date:

Previous
From: Kevin Kempter
Date:
Subject: Query tuning
Next
From: Scott Carey
Date:
Subject: Re: Query tuning