Received: from localhost (unknown [200.46.204.184]) by postgresql.org (Postfix) with ESMTP id 62E272E2E89 for ; Thu, 6 Mar 2008 01:50:56 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.184]) (amavisd-maia, port 10024) with ESMTP id 99702-04 for ; Thu, 6 Mar 2008 01:50:52 -0400 (AST) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.5 Received: from qb-out-0506.google.com (qb-out-0506.google.com [72.14.204.236]) by postgresql.org (Postfix) with ESMTP id 972AB2E2E56 for ; Thu, 6 Mar 2008 01:50:53 -0400 (AST) Received: by qb-out-0506.google.com with SMTP id o12so1645749qba.17 for ; Wed, 05 Mar 2008 21:50:52 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:user-agent:mime-version:to:cc:subject:references:in-reply-to:content-type:content-transfer-encoding; bh=vF6ZKu2rm0hqDdCDqAEQCrLSh4iJB0PPnqNJSEGfa+E=; b=hC88eCJNFALNr87M9OxJc/YhtlSXaPf5+GSgly06J6sSYAuxLDsLXlqkGmT45Xpo0gp4N6x/XvnoHuEZ/ZFmYDQ/0iJxqDo7PS++2dKUzbAM5XiWQIzacWnOrrrB/pRWT3QTEWHCsAaHh6v7vin8sZYO/+dG1DjVsM82A9FZXR4= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:user-agent:mime-version:to:cc:subject:references:in-reply-to:content-type:content-transfer-encoding; b=KZVkiFFh0Pr22r+O/WI77YWpKSI6KDCdOv0Zd/rDivfGRKl+goRHc/6DO0SPG2jmk9aTrpqVkCLoXK1n4dy9wwKoQQ9DYFD34oa5eA8gy1bCevHs19BceTyqgJ7dlRBApvdb/bSMsk+BIKysJPCiSjTRWpQ7PG/vyg5sPadUOWQ= Received: by 10.114.183.1 with SMTP id g1mr6212191waf.3.1204782652347; Wed, 05 Mar 2008 21:50:52 -0800 (PST) Received: from ?10.1.1.19? ( [203.217.18.65]) by mx.google.com with ESMTPS id m29sm3554958poh.3.2008.03.05.21.50.50 (version=TLSv1/SSLv3 cipher=RC4-MD5); Wed, 05 Mar 2008 21:50:51 -0800 (PST) Message-ID: <47CF85A3.8080407@gmail.com> Date: Thu, 06 Mar 2008 16:48:19 +1100 From: Chris User-Agent: Thunderbird 2.0.0.12 (Windows/20080213) MIME-Version: 1.0 To: sathiya psql CC: pgsql-performance@postgresql.org Subject: Re: count * performance issue References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200803/88 X-Sequence-Number: 29042 sathiya psql wrote: > count(*) tooks much time... > > but with the where clause we can make this to use indexing,... what > where clause we can use?? > > Am using postgres 7.4 in Debian OS with 1 GB RAM, > > am having a table with nearly 50 lakh records, Looks suspiciously like a question asked yesterday: http://archives.postgresql.org/pgsql-performance/2008-03/msg00068.php -- Postgresql & php tutorials http://www.designmagick.com/