views:

42

answers:

1

Why is COUNT(*) so much quicker than COUNT(field), Even when field is an index?

I am using MySQL

+3  A: 

COUNT(field) will not count that row when field is null, so there is an additional check it must do.

COUNT(*) simply counts rows.

RedFilter