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 / v.krishnakumar

using the keyword distinct we can avoid the duplicate value
in our table,(ex) SELECT DISTINCT empname FROM Employee

Is This Answer Correct ?    0 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is database mirroring?

1172


Difference between 2NF &3NF ?

1127


What do you mean by data integrity?

1123


What is bit data type?

1075


what is a correlated sub-query? : Sql server database administration

985


what is dbcc? : Sql server database administration

1075


What are relationships and mention different types of relationships in the dbms

1011


when would you go for denormalization? : Sql server database administration

906


Explain about Views?

1120


What is difference between materialized view and view?

947


Can sql servers link to other servers?

1130


Are all views updatable ?

1197


How to create a dml trigger using create trigger statements?

1076


What are the features of Embedded SQL

1170


What is the difference between dbcc indexdefrag and dbcc reindex?

1029