Approximate Count of Unique Values in SQL Server

In my previous blog, I discussed the approximate count of unique values for which a predefined function is available in Impala (NDV), Oracle 12c (APPROX_COUNT_DISTINCT) and in MongoDB (estimatedDocumentCount()). 

However, I didn’t mention about SQL Server since there is no such function available in the versions I am using. However, the function has been introduced in SQL Server 2019.

The function Approx_Count_Distinct does the same thing as mentioned in my previous blog. 

If you want to know more about this function, I would suggest you click here. This guy (Rajendra Gupta) didn’t leave any opportunity to discuss this functionality as he concentrated on each piece and clarified each and every point.

 

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s