X-Original-To: pgsql-sql-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 1DE66529D2 for ; Wed, 10 Aug 2005 07:51:12 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 88009-03 for ; Wed, 10 Aug 2005 10:51:00 +0000 (GMT) Received: from smtp104.rog.mail.re2.yahoo.com (smtp104.rog.mail.re2.yahoo.com [206.190.36.82]) by svr1.postgresql.org (Postfix) with SMTP id 9349452B92 for ; Wed, 10 Aug 2005 07:50:58 -0300 (ADT) Received: (qmail 86687 invoked from network); 10 Aug 2005 10:51:01 -0000 Received: from unknown (HELO phlogiston.dydns.org) (a.sullivan@rogers.com@216.75.167.195 with login) by smtp104.rog.mail.re2.yahoo.com with SMTP; 10 Aug 2005 10:51:01 -0000 Received: by phlogiston.dydns.org (Postfix, from userid 1000) id D0229412B; Wed, 10 Aug 2005 06:50:59 -0400 (EDT) Date: Wed, 10 Aug 2005 06:50:59 -0400 From: Andrew Sullivan To: pgsql-sql@postgresql.org Subject: Re: **SPAM** Faster count(*)? Message-ID: <20050810105059.GA5448@phlogiston.dyndns.org> References: <000101c59d33$36a4a560$9b00015a@osl.com> <196456155.20050810012958@karneval.cz> <21626.1123642154@sss.pgh.pa.us> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <21626.1123642154@sss.pgh.pa.us> User-Agent: Mutt/1.5.9i X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.042 tagged_above=0 required=5 tests=AWL, FORGED_RCVD_HELO X-Spam-Level: X-Archive-Number: 200508/46 X-Sequence-Number: 22274 On Tue, Aug 09, 2005 at 10:49:14PM -0400, Tom Lane wrote: > > Current best practice is to run the explain and parse out the "rows" > figure using a perl (or axe-of-choice) regexp, though we could be > persuaded to supply a simpler API if there's enough demand for it. FWIW, this was another one of those things I must have heard a dozen times at OSCON. I suspect the simpler API would be popular, particularly since post-8.0 the estimates are more reliable than they used to be. A -- Andrew Sullivan | ajs@crankycanuck.ca The whole tendency of modern prose is away from concreteness. --George Orwell