Received: from maia.hub.org (maia-3.hub.org [200.46.204.243]) by mail.postgresql.org (Postfix) with ESMTP id 85188636780 for ; Tue, 22 Jun 2010 14:33:32 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.243]) (amavisd-maia, port 10024) with ESMTP id 36544-04 for ; Tue, 22 Jun 2010 17:33:25 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from gw.wicourts.gov (gwmta.wicourts.gov [165.219.244.99]) by mail.postgresql.org (Postfix) with ESMTP id 4BC4F6329BB for ; Tue, 22 Jun 2010 14:33:25 -0300 (ADT) Received: from Courts-MTA by gw.wicourts.gov with Novell_GroupWise; Tue, 22 Jun 2010 12:33:24 -0500 Message-Id: <4C20AD8B0200002500032812@gw.wicourts.gov> X-Mailer: Novell GroupWise Internet Agent 8.0.1 Date: Tue, 22 Jun 2010 12:33:15 -0500 From: "Kevin Grittner" To: , Subject: Re: postgres query is very slow References: <3147.131.215.15.78.1277227423.squirrel@webmail.caltech.edu> In-Reply-To: <3147.131.215.15.78.1277227423.squirrel@webmail.caltech.edu> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Content-Disposition: inline X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-4.21 tagged_above=-10 required=5 tests=BAYES_00=-1.9, RCVD_IN_DNSWL_MED=-2.3, T_RP_MATCHES_RCVD=-0.01 X-Spam-Level: X-Archive-Number: 201006/176 X-Sequence-Number: 34954 wrote: > I built a database on postgres8.1, then I did VACUUM FULL ANALYZE, > but the query is still slow. > Has anybody an idea ? I recommend you re-post to the pgsql-performance list, after reading this: http://wiki.postgresql.org/wiki/SlowQueryQuestions The one thing I can say based on the information you've provided so far is that you can expect major performance improvements if you upgrade to a new major release of PostgreSQL. Well, there is one other thing -- it's almost never a good idea to run VACUUM FULL. You may have bloated your indexes. You could try a REINDEX on the database. -Kevin