Re: table configuration tweak for performance gain.

From: Michael Fuhr <mike(at)fuhr(dot)org>
To: "Harvey, Allan AC" <HarveyA(at)OneSteel(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: table configuration tweak for performance gain.
Date: 2004-11-17 02:45:32
Message-ID: 20041117024526.GA45526@winnie.fuhr.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Wed, Nov 17, 2004 at 12:41:20PM +1100, Harvey, Allan AC wrote:

> mill2=> explain analyse select count(*) from history where pointname = 'MILL2-SPEED' and dt > (now() - interval '5 minutes')::timestamp\g

How typical is this query? How many distinct values does pointname
have? Have you considered adding an index on pointname or a multicolumn
index on pointname and dt?

--
Michael Fuhr
http://www.fuhr.org/~mfuhr/

In response to

Browse pgsql-general by date

  From Date Subject
Next Message matthias 2004-11-17 04:43:48 Re: Problems importing Unicode
Previous Message Harvey, Allan AC 2004-11-17 01:41:20 Re: table configuration tweak for performance gain.