Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

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


Please Help Members By Posting Answers For Below Questions

What are the restrictions while creating batches in sql server?

1062


What is the difference between a clustered index and a non-clustered index?

991


Explain the dirty pages?

1005


How to fetch the next row from a cursor with a "fetch" statement?

1073


Explain having clause?

965


Which data type columns are the best candidates for full-text indexing?

967


What is the cartesian product of table?

1009


Why use sub query in sql server and list out types of sub queries?

999


Define views.

1012


What are the restrictions that views have to follow?

972


What does select 1 mean?

925


What is difference between foreign key and unique key?

1011


What are the advantages of using cte?

1015


Define Wed Edition in SQL Azure?

100


How to assign null values to variables or columns?

973