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

Write a single SQL to delete duplicate records from the a
single table based on a column value. I need only Unique
records at the end of the Query.

Answer Posted / guest

Hope this will help,

DELETE FROM EMPLOYEE
WHERE (EMP_ID,EMP_NAME) IN
(SELECT EMP_ID,EMP_NAME FROM
(SELECT EMP_ID,EMP_NAME ,ROW_NUMBER() OVER (PARTITION BY
EMP_ID,EMP_NAME ORDER BY EMP_ID,EMP_NAME) AS FLG
FROM EMPLOYEE) A
WHERE
A.FLG<>1)

Is This Answer Correct ?    4 Yes 10 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Hi send me the Teradata dumps to my id rajeshanantha@yahoo.co.in Thanks Rajesh. A

3374


What is the purpose of joins in teradata?

1191


Where is teradata rdbms used?

1102


What is basic teradata query language?

1118


Explain teradata vs. Redshift?

1028


What are the string manipulation operators and functions associated with teradata?

1097


Difference between inner join and outer join?

1033


What are the various etl tools in the market?

1074


What is the primary index in teradata?

1206


Differentiate primary key and partition key?

984


Let us say there is a file that consists of 100 records out of which we need to skip the first and the last 20 records. What will the code snippet?

1204


Explain teradata architecture?

1098


What are the uses of client software involved in teradata?

984


What is meant by a Highest Cost Plan?

1063


What is a node in teradata?

1002