Delete duplicate rows from a table without primary key by
using a single query
Table Employee
empname salary
A 200
B 300
A 200
C 400
D 500
D 500
Output should be
A 200
B 300
C 400
D 500
Answer Posted / navneet sharma
select distinct * from tablename
| Is This Answer Correct ? | 4 Yes | 1 No |
Post New Answer View All Answers
What is history table in sql server?
What are the types of subquery?
Where do we use trace frag?
Do you know what is difference between index seek vs. Index scan?
You have modified 100 store procedures and want to replicate these changes from development to prodution, and production can have users using the Server/DB, how would you replicate without causing issues?
What is log in sql server?
List the various tools available for performance tuning?
What is sql server database?
What are the restrictions that views have to follow? : SQL Server Architecture
Is it ok to shrink transaction log?
What is scheduled job and how to create it?
What is the template in sql?
Mention the differences between substr and charindex in sql server.
Call by value and call by reference in procedure and function, with NOCOPY.
How to install sql server 2005 express edition?