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
What are the available primary index types in teradata.
What is the use of teradata system software?
What is the opening step in basic teradata query script?
Explain BYNET.
Highlight the advantages of PPI(Partition Primary Index).
If a Node is busy what are the steps you can take to avoid ?
What is logical data model?
What are the string manipulation operators and functions associated with teradata?
Difference between multiload and tpump?
What is difference between user and database in teradata?
how can we analyze the locks ?
What is the syntax for case when statement?
What are the different functions performed in development phase?
How do you determine the number of sessions?
Which is faster fastload or multiload?