X-Original-To: pgsql-performance@postgresql.org Received: from localhost (postgresql.org [64.49.215.8]) by postgresql.org (Postfix) with ESMTP id A0ED0476176 for ; Tue, 4 Mar 2003 10:15:29 -0500 (EST) Received: from postgresql.org ([64.49.215.8]) by localhost (postgresql.org [64.49.215.8:10024]) (amavisd-new) with SMTP id 06985-10 for ; Tue, 4 Mar 2003 10:15:25 -0500 (EST) Received: from mail.libertyrms.com (unknown [209.167.124.227]) by postgresql.org (Postfix) with ESMTP id E999A476170 for ; Tue, 4 Mar 2003 10:15:24 -0500 (EST) Received: from andrew by mail.libertyrms.com with local (Exim 3.22 #3 (Debian)) id 18qE8f-0000BO-00 for ; Tue, 04 Mar 2003 10:15:29 -0500 Date: Tue, 4 Mar 2003 10:15:29 -0500 From: Andrew Sullivan To: pgsql-performance@postgresql.org Subject: Re: Slow query performance on large table Message-ID: <20030304101529.D32416@mail.libertyrms.com> Mail-Followup-To: Andrew Sullivan , pgsql-performance@postgresql.org References: <000001c2e25c$ad506170$0c64a8c0@paulspc> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <000001c2e25c$ad506170$0c64a8c0@paulspc>; from paul_mckay@clearwater-it.co.uk on Tue, Mar 04, 2003 at 02:45:18PM -0000 X-Virus-Scanned: by amavisd-new X-Archive-Number: 200303/8 X-Sequence-Number: 1306 On Tue, Mar 04, 2003 at 02:45:18PM -0000, Paul McKay wrote: > > Select time,value > > >From measurement > > Where assessment = ? > > And time between ? and ? > Please run this with EXPLAIN ANALYSE with values that slow the query down. By bet is that you have an index which needs wider statistics setting on the column to be useful, but without the output from EXAPLIN ANALYSE it'll be hard to tell. A -- ---- Andrew Sullivan 204-4141 Yonge Street Liberty RMS Toronto, Ontario Canada M2P 2A8 +1 416 646 3304 x110