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

Nested query method might be required in other databases
how ever in TD we don’t need to follow such a difficult way
to just find out the unique rows.

In TD we have functions like Rank () and Rownum() in the
combination of Qualify, helps you to select out the rows
which you wants to delete.

you can add a condition like ‘Where Rank() > 1’

Is This Answer Correct ?    3 Yes 16 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is smp and mpp platforms?

531


Highlight the advantages of PPI(Partition Primary Index).

565


What does Amp contain and what are all the operations that it performs?

594


Difference between stored procedure and macro?

693


if collect stats but it show low confidence why?

1194






What is difference between user and database in teradata?

620


what are the uses of fact table and dimension table in banking project?

4108


How many sessions of MAX is PE capable of handling at a particular time?

599


Discuss the advantages of using partitioned primary index in a query?

539


What is the meaning of Caching in Teradata?

695


Syntax for case when statement?

616


If RDBMS is halted what will you do ?

1712


What is meant by a Virtual Disk?

580


Comment whether bottleneck is an error or not.

625


tomorrow i have interview in infosys.can someone pour any suggestions or any interview questions. thank you

380