Received: from localhost (maia-2.hub.org [200.46.204.187]) by postgresql.org (Postfix) with ESMTP id 81E0D9FC2F0 for ; Fri, 18 May 2007 11:00:15 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.187]) (amavisd-maia, port 10024) with ESMTP id 15168-04-3 for ; Fri, 18 May 2007 10:59:59 -0300 (ADT) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.5 Received: from nz-out-0506.google.com (nz-out-0506.google.com [64.233.162.228]) by postgresql.org (Postfix) with ESMTP id 2391E9FC2EF for ; Fri, 18 May 2007 11:00:04 -0300 (ADT) Received: by nz-out-0506.google.com with SMTP id s1so1400288nze for ; Fri, 18 May 2007 07:00:03 -0700 (PDT) DKIM-Signature: a=rsa-sha1; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=fayLFDQ+EemhESiYyJhAxWVZClBmSQrQCOtjGUO3TepBcEjmqYibyDvkWsF8mHsL8ibJO49Cq6PXCCttXMCqqj1x28GN37RAhj46OSRwJKvQmRrw4F3VNnFEJqPmemgZ6zs7QAQBCwf8jLuGSJBxeydMMHvn1Qfl3oUakDEedIE= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=YydPLEU0nlApTZfk9rxCv3xHakh5/JEOIoxDCwNKImMh/vHyZAcO+dt3UCaYYn+y45VaJWl8PmJ8rKSL2d8F2HXBqusafh1fNddcZPX6rYzS4jJ501VhcN/cNO9ZDUx+7P6Iynx3GtyOrmWDJIVffHYm0PMAo7m/7F0HUeQoOIk= Received: by 10.114.37.1 with SMTP id k1mr893401wak.1179496802144; Fri, 18 May 2007 07:00:02 -0700 (PDT) Received: by 10.114.47.12 with HTTP; Fri, 18 May 2007 07:00:01 -0700 (PDT) Message-ID: <36e682920705180700n7a6df052pfbbc19ba185886f8@mail.gmail.com> Date: Fri, 18 May 2007 10:00:01 -0400 From: "Jonah H. Harris" To: "Daniel Cristian Cruz" Subject: Re: select count(*) from a large table is very slow Cc: "Kenneth Marshall" , "Jessica Richard" , pgsql-admin@postgresql.org In-Reply-To: <48d0cacb0705180658n1ce65297xa9f28d56dd4f8426@mail.gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <133912.35849.qm@web56406.mail.re3.yahoo.com> <20070518131920.GA7069@it.is.rice.edu> <36e682920705180630y2c28cdc5m14af94d6d62e1daf@mail.gmail.com> <48d0cacb0705180658n1ce65297xa9f28d56dd4f8426@mail.gmail.com> X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200705/188 X-Sequence-Number: 25508 On 5/18/07, Daniel Cristian Cruz wrote: > Oops... INSERT or DELETE... :) Heh, yeah... doh! > And remember that if using TRUNCATE, it will not run your trigger and > you will need to reset the counter manually. Correct. -- Jonah H. Harris, Software Architect | phone: 732.331.1324 EnterpriseDB Corporation | fax: 732.331.1301 33 Wood Ave S, 3rd Floor | jharris@enterprisedb.com Iselin, New Jersey 08830 | http://www.enterprisedb.com/