Re: Why count(*) doest use index?

From: John R Pierce <pierce(at)hogranch(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: Re: Why count(*) doest use index?
Date: 2011-03-05 22:46:47
Message-ID: 4D72BD57.8090801@hogranch.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On 03/05/11 2:05 PM, Allan Kamau wrote:
> Is it possible in theory to efficiently perform count the primary or
> unique indices underlying data structures, regardless whether there is
> a WHERE clause detailing filtration base on values from such index or
> not?

indexes are not exact, due to possibly constant changes in the current
number of visible elements in the relation.

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Willy-Bas Loos 2011-03-05 23:25:40 Re: Why count(*) doest use index?
Previous Message John R Pierce 2011-03-05 22:44:52 Re: PHP array to PlPgSQL arrat. How to?