Hi, experts,
I have a question to consult you. I have a table which contains some duplicate records on some columns. Some of them have two duplicate records, and some of tme have three, and so on. I can find them but I want to keep only one and delete others.
For example,
select id, dept, name, location
from tab
group by id, dept, name, location
having count(*) > 1;
Thanks very much.
Jeanne
I have a question to consult you. I have a table which contains some duplicate records on some columns. Some of them have two duplicate records, and some of tme have three, and so on. I can find them but I want to keep only one and delete others.
For example,
select id, dept, name, location
from tab
group by id, dept, name, location
having count(*) > 1;
Thanks very much.
Jeanne