Difference Between Count and Count_Big Functions in SQL Server

Hello everyone,

In this article, I will give information about the difference between Count and Count_Big functions in SQL Server.

There is no difference in functionality between Count and Count_Big. They are almost the same. The only difference is the data type they return and the indexing on the view.

When you use the COUNT(*) function, it returns the data type as INT (range: -2^31 (-2.147.483.648) to 2^31-1 (2.147.483.647) and storage 4 bytes), while using COUNT_BIG(*) it returns data as BIGINT type (range: -2^63 (-9,223,372,036,854,775,808) to 2^63-1 (9,223,372,036,854,775,807) and storage 8 bytes).

Good luck to everyone in business and life.

140 Views

Yavuz Selim Kart

I try to explain what I know in software and database. I am still improving myself by doing research on many programming languages. Apart from these, I am also interested in Graphic Design and Wordpress. I also have knowledge about SEO and Social media management. In short, I am a determined person who likes to work hard.

You may also like...

Don`t copy text!