Обсуждение: performance difference in count(1) vs. count(*)?

Поиск
Список
Период
Сортировка

performance difference in count(1) vs. count(*)?

От
Markus Bertheau
Дата:
Hello,

is there a difference performance-wise between select count(1) and
select count(*)?

-- 
Markus Bertheau.
Berlin, Berlin.
Germany.



Re: performance difference in count(1) vs. count(*)?

От
Tom Lane
Дата:
Markus Bertheau <twanger@bluetwanger.de> writes:
> is there a difference performance-wise between select count(1) and
> select count(*)?

Nope.  In fact, the latter is converted to the former during parsing.
        regards, tom lane