in tabase table having a column in it empname field is
there which having 5 duplicate values is there i want
deleted all the duplicates i want showing only one name
only.
Answer Posted / dinesh gupta
Kumar your query do not solve the purpose accurately.
It should be as
Delete from employee where empid
not in (Select min(empid) from employee group by empname
having count(empname)>=1)
| Is This Answer Correct ? | 1 Yes | 1 No |
Post New Answer View All Answers
Explain transaction server explicit transaction?
How can we rewrite sub-queries into simple select statements or with joins?
What do we have to check in database testing?
Create a dts package to produce a text file using the ‘update statistics’ command for the tables in a database with obsolete statistics.
Which command is used for user defined error messages?
What is set nocount on and what is set nocount off?
What is the difference between implicit and explicit transaction?
What is use of attribute hierarchy optimized state? : sql server analysis services, ssas
What number sorts of privileges are accessible in sql?
What is the ‘fillfactor’?
What is the difference between NOROW and LOCKROW?
Explain what are sparse columns?
what is a self join? : Sql server database administration
What are the different types of backups that exist?
Do you know what is a trace frag? Where do we use it?