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 records from the table?(Table must have
unique id)

Answer Posted / brijesh darmwal, sandhya

DELETE FROM [MyDb].[dbo].[sandhya]
WHERE id
IN
(SELECT id
FROM
(SELECT MAX(id) as id,name,addr
FROM [MyDb].[dbo].[sandhya] GROUP BY name,addr having
count(id)>=2)
Tmp)

Is This Answer Correct ?    7 Yes 16 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

explain the storage models of olap? : Sql server database administration

877


What is a covered index?

889


Mention the command used to rename the database.

944


Define inner join? Explain with an example?

920


Explain an incremental backup?

936


How to delete duplicate rows from table except one?

930


Is port 1433 secure?

929


What is data source view or dsv? : sql server analysis services, ssas

946


What are the advantages of log shipping?

928


how you can configure a running aggregate in SSRS?

184


What is repeatable read?

932


What is an expensive query?

877


What are different types of subquery?

1174


Write a program to fetch first 10 records from a file?

960


How to use wildcard characters in like operations in ms sql server?

1058