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 are the restrictions while creating batches in sql server?
What is the difference between a clustered index and a non-clustered index?
Explain the dirty pages?
How to fetch the next row from a cursor with a "fetch" statement?
Explain having clause?
Which data type columns are the best candidates for full-text indexing?
What is the cartesian product of table?
Why use sub query in sql server and list out types of sub queries?
Define views.
What are the restrictions that views have to follow?
What does select 1 mean?
What is difference between foreign key and unique key?
What are the advantages of using cte?
Define Wed Edition in SQL Azure?
How to assign null values to variables or columns?