What is the difference between the following two sql
statements
select count(*) from <tablename>
select count(col_name) from <tablename>
Answer Posted / sandeep
select count(*) from <tablename>
- return number of records from table
select count(col_name) from <tablename>
- return number of records where col_name is NOT NULL
- Null value is eliminated by an aggregate or other SET
operation.
Is This Answer Correct ? | 5 Yes | 0 No |
Post New Answer View All Answers
How you can add messages to the nt event log from within a stored procedure?
Explain the cursor lock types?
How to change the system date and time from SQL Plus Terminal ?
I have triggers,views,functions,stored Procedures for a table. When I am dropping that table which objects are deleted?
What is normalization process?
What is a linked server in sql server?
Determine when to use stored procedure to complete sql server tasks?
In case you have filters in your report, when filters will be applied in cached report instance?
What is function of CUBE ?
What is the difference between stored procedure and user defined functions?
What are the five major components of a dbms?
what are user defined datatypes? : Sql server database administration
What is the tcp/ip port on which sql server runs?
Define Joins?
Detail about the hardware which is supported by SQL server?