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 / kumar

Table structure :-

empid empname
1 bala
2 bala
3 bala
4 bala
5 arun
6 arun
7 arun
8 ram
9 ram

Delete from employee where empid
not in (Select min(empid) from employee group by emp
having count(empid)>1)

By
Kumar

Is This Answer Correct ?    1 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

In what version of sql server were synonyms released?

908


What are the types of sql server?

992


How will you hide an attribute? : sql server analysis services, ssas

893


How do I find the transaction log size in sql server?

917


What are triggers in ms sql server?

1105


Can we deploy SSRS reports on our personal website?

162


Write an sql query for deleting duplicate rows?

955


Explain trigger and its types?

1014


Describe and explain about SQL native client?

1041


What are the new features introduced in SQL Server 2000 (or the latest release of SQL Server at the time of your interview)? What changed between the previous version of SQL Server and the current version?

1023


Issues related in upgrading SQL Server 2000 to 2005 / 2008

1834


Explain primary key and foreign key constraints?

966


What is resource governor?

927


what are different types of raid configurations? : Sql server database administration

995


How to create user defined functions with parameters?

1166