How to get the count of distinct records. Please give me the
query?

Answer Posted / madhavi.bandreddi

select count(*) from (select distinct * from tablename)as
dummytable

Is This Answer Correct ?    3 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How to throw custom exception in Stored Procedure?

582


Issues related in upgrading SQL Server 2000 to 2005 / 2008

1505


How can a user-defined datatype be created?

545


What is hierarchy, what are its types and difference between them? : sql server analysis services, ssas

702


What is the maximum size of a row in sql server?

529






What do you need to connect php to sql server?

545


How to end a stored procedure properly in ms sql server?

550


Explain sql server service broker?

515


Define right outer join in sql server joins?

521


What is model database? : SQL Server Architecture

574


What are different types of collation sensitivity?

542


Do you know what is bit data type and whats the information that can be stored inside a bit column?

558


how many layers of tcp/ip protocol combined of? : Sql server database administration

531


Do you know concepts and capabilities of sql server?

584


Can we join two tables without primary key?

619