Skip site navigation (1) Skip section navigation (2)

Re: Good News re count(*) in 8.1

From: Greg Stark <gsstark(at)mit(dot)edu>
To: "Kevin Grittner" <Kevin(dot)Grittner(at)wicourts(dot)gov>
Cc: <pgsql-performance(at)postgresql(dot)org>
Subject: Re: Good News re count(*) in 8.1
Date: 2006-02-23 03:52:48
Message-ID: 87irr6zq7j.fsf@stark.xeocode.com (view raw or flat)
Thread:
Lists: pgsql-performance
"Kevin Grittner" <Kevin(dot)Grittner(at)wicourts(dot)gov> writes:

> There have been several times that I have run a SELECT COUNT(*) on an entire
> table on all central machines. On identical hardware, with identical data,
> and equivalent query loads, the PostgreSQL databases have responded with a
> count in 50% to 70% of the time of the commercial product, in spite of the
> fact that the commercial product does a scan of a non-clustered index while
> PostgreSQL scans the data pages.

I take it these are fairly narrow rows? The big benefit of index-only scans
come in when you're scanning extremely wide tables, often counting rows
matching some indexed criteria.

-- 
greg


In response to

Responses

pgsql-performance by date

Next:From: Andreas PflugDate: 2006-02-23 10:21:26
Subject: Re: Joins and full index scans...mysql vs postgres?
Previous:From: Christopher Kings-LynneDate: 2006-02-23 02:52:11
Subject: Re: Joins and full index scans...mysql vs postgres?

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group