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

How to retrieve duplicate rows in a table?
How to delete the duplicate entries in a table?

Answer Posted / gaurav jain

begin
select distinct * into #one from four where id in (select
id from four group by id
having count(*)>1)
delete from four where id in (select id from four group by
id having count(*)>1)
insert into four select * from #one
end

Is This Answer Correct ?    0 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How much is a sql server license?

953


Explain steps of normalization?

1004


Why is the need for data conversion transformations?

1067


What are two difference between sql azure and azure tables?

159


Why it is recommended to avoid referencing a floating point column in the where clause?

966


List the data types available in mssql?

1033


Explain the use of keyword with encryption. Create a store procedure with encryption?

961


Can we update data in a view?

1032


What is the use of toad or sqldbx.?

1156


Do you know what is user defined datatypes and when you should go for them?

968


How to connect a database with sql express.?

1062


What is Extended user-defined?

960


How dts is used to extract, transform and consolidate data?

1073


What are the underflow and overflow behaviors on float literals?

1113


Explain sql server authentication modes?

1130