pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Shridhar Daithankar <shridhar_daithankar@persistent.co.in>
To: Dror Matalon <dror@zapatec.com>
Cc: pgsql-performance@postgresql.org
Subject: Re: Various performance questions
Date: Mon, 27 Oct 2003 12:52:27 +0530
Message-ID: <3F9CC7B3.2090501@persistent.co.in> (raw)
In-Reply-To: <20031027071703.GF2979@rlx11.zapatec.com>
References: <20031026194449.GD2979@rlx11.zapatec.com>
	<87u15vxrue.fsf@stark.dyndns.tv>
	<20031027045431.GE2979@rlx11.zapatec.com>
	<m3r80zmd1a.fsf@wolfe.cbbrowne.com>
	<20031027071703.GF2979@rlx11.zapatec.com>

Dror Matalon wrote:

> On Mon, Oct 27, 2003 at 01:04:49AM -0500, Christopher Browne wrote:
>>Most of the time involves:
>>
>> a) Reading each page of the table, and
>> b) Figuring out which records on those pages are still "live."
> 
> 
> The table has been VACUUM ANALYZED so that there are no "dead" records.
> It's still not clear why select count() would be slower than select with
> a "where" clause.

Do a vacuum verbose full and then everything should be within small range of 
each other.

Also in the where clause, does explicitly typecasting helps?

Like 'where channel<5000::int2;'

  HTH

  Shridhar




view thread (23+ messages)  latest in thread

Message-ID: <3F9CC7B3.2090501@persistent.co.in>
Permalink:  ../3F9CC7B3.2090501@persistent.co.in/
Also on:    postgresql.org/message-id/3F9CC7B3.2090501@persistent.co.in

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-performance@postgresql.org
  Cc: shridhar_daithankar@persistent.co.in, dror@zapatec.com
  Subject: Re: Various performance questions
  In-Reply-To: <3F9CC7B3.2090501@persistent.co.in>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox