RE: Performance off "count(*)"

From: Tanel Poder <>
Date: Sun, 20 Jul 2008 15:15:51 +0800
Message-id: <91825A5F214B4DAD91AA138A2F4107EF@windows01>

Hi Greg,

> -----Original Message-----
> From:
> [] On Behalf Of Greg Rahn
> Sent: Sunday, July 20, 2008 07:06
> To: Tanel Poder
> Cc:
> Subject: Re: Performance off "count(*)"
> I think we are saying the same thing: the count can be
> determined by just the block header. No?

Nope, as far as I know (and have elaborated in other posts in this thread) the rowcount can *not* be detected by reading the block header only. The reason is that the row count field in block header includes also deleted rows and continued rowpieces of chained rows which you shouldn't count.

Tanel Poder

Received on Sun Jul 20 2008 - 02:15:51 CDT

Original text of this message