Re: which one is faster

From: Grzegorz Jaśkiewicz <gryzman(at)gmail(dot)com>
To: Szymon Guz <mabewlun(at)gmail(dot)com>
Cc: Marcin Mirosław <marcin(at)mejor(dot)pl>, pgsql-performance(at)postgresql(dot)org
Subject: Re: which one is faster
Date: 2010-10-26 12:20:33
Message-ID: AANLkTimx3bcBoxVeU1CLVONGn+UE-Cf14UzNPgciL6Vp@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

2010/10/26 Szymon Guz <mabewlun(at)gmail(dot)com>:
>
> Well, strange. Why is that slower?

To answer that fully, you would need to see the implementation.
suffice to say,

count(a) does:

if (a <> NULL)
{
count++;
}

and count(*) does:

count++;

--
GJ

In response to

Responses

Browse pgsql-performance by date

  From Date Subject
Next Message Szymon Guz 2010-10-26 12:23:21 Re: which one is faster
Previous Message Szymon Guz 2010-10-26 12:16:31 Re: which one is faster