The Difference between 'Count' and 'Count(*)'

Answer Posted / sachin rathi

Count(column name or exp) returns the no. of records for a
specific/particular column of table excluding null values
whereas Count(*) returns all the rows/records in the table
including duplicated and null values

Is This Answer Correct ?    6 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How do I uninstall sql server 2014?

699


What is use of attributehierarchyenabled? : sql server analysis services, ssas

847


What is the difference between set and select?

778


What is the difference between SQL notification and SQL invalidation?

821


What are distributed partitioned views?

840


How to add a new column to an existing table with "alter table ... Add" in ms sql server?

780


Do you know how to store and query spatial data?

806


What is the name of the system variable that returns the number of rows affected by a SQL statement?

800


What is format parameter in ssrs?

130


Explain what are the basic functions for master, msdb, model, tempdb databases?

731


How to find the list of fixed hard drive and free space on server?

801


How we can refresh the view?

832


What is a domain constraint give an example?

814


Mention the uses of stored procedures.

757


Explain different types of index?

796