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...

in tabase table having a column in it empname field is
there which having 5 duplicate values is there i want
deleted all the duplicates i want showing only one name
only.

Answer Posted / karna

delete from emp where empid not in(select max(empid) from
emp group by empname having count(*)>=1)

Is This Answer Correct ?    2 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are the new data types are introduced in sql 2000?

895


Which database stores information about replication?

1054


How can you start sql server in different modes?

961


What are the advantages of the mirroring?

1075


How do I start sql server?

963


What is the syntax for encrypting a column in SQL Server?

1108


Tell me when is the update_statistics command used?

1098


Explain what is the use of custom fields in report?

909


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

983


How do I start sql server agent automatically?

958


Delete duplicate rows without using rowid.

1530


Is null in sql server?

978


Explain few examples of RDBMS?

1032


What is explicit mode in sql server?

1049


What is amo? : sql server analysis services, ssas

1085