X-Original-To: pgsql-sql-postgresql.org@localhost.postgresql.org Received: from localhost (mx1.hub.org [200.46.208.251]) by postgresql.org (Postfix) with ESMTP id 3AA619FA19B for ; Thu, 11 May 2006 14:18:18 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.208.251]) (amavisd-new, port 10024) with ESMTP id 43657-03 for ; Thu, 11 May 2006 14:18:10 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey- Received: from r1.mycybernet.net (r1.mycybernet.net [209.5.206.8]) by postgresql.org (Postfix) with ESMTP id 86F759FA278 for ; Thu, 11 May 2006 14:18:10 -0300 (ADT) Received: from 227-54-222-209.mycybernet.net ([209.222.54.227]:52056 helo=phlogiston.dydns.org) by r1.mycybernet.net with esmtp (Exim 4.50 (FreeBSD)) id 1FeEng-0003Kj-SG for pgsql-sql@postgresql.org; Thu, 11 May 2006 13:18:09 -0400 Received: by phlogiston.dydns.org (Postfix, from userid 1000) id 70F983FAF; Thu, 11 May 2006 13:18:08 -0400 (EDT) Date: Thu, 11 May 2006 13:18:08 -0400 From: Andrew Sullivan To: pgsql-sql@postgresql.org Subject: Re: Help with a seq scan on multi-million row table Message-ID: <20060511171808.GB9089@phlogiston.dyndns.org> References: <44631313.1020100@logix-tt.com> <20060511170944.91199.qmail@web50302.mail.yahoo.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20060511170944.91199.qmail@web50302.mail.yahoo.com> User-Agent: Mutt/1.5.9i X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200605/102 X-Sequence-Number: 25133 On Thu, May 11, 2006 at 10:09:44AM -0700, ogjunk-pgjedan@yahoo.com wrote: > Hi Markus & Tom, > > Higher statistics for this column.... hm, I'd love to try changing > it to see how that changes things, but I'm afraid I don't know how > to do that. How can I change the statistics target value for this > column? > > Ah, I think I found the place: No. Just ALTER TABLE [name] ALTER [column] SET STATISTICS. See http://www.postgresql.org/docs/8.1/interactive/sql-altertable.html for more. You'll need to ANALYSE afterwards. A -- Andrew Sullivan | ajs@crankycanuck.ca In the future this spectacle of the middle classes shocking the avant- garde will probably become the textbook definition of Postmodernism. --Brad Holland