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 is history table in sql server?

911


What are the types of subquery?

996


Where do we use trace frag?

982


Do you know what is difference between index seek vs. Index scan?

915


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?

2107


What is log in sql server?

1099


List the various tools available for performance tuning?

851


What is sql server database?

954


What are the restrictions that views have to follow? : SQL Server Architecture

956


Is it ok to shrink transaction log?

949


What is scheduled job and how to create it?

937


What is the template in sql?

932


Mention the differences between substr and charindex in sql server.

1000


Call by value and call by reference in procedure and function, with NOCOPY.

1256


How to install sql server 2005 express edition?

1068