This is what i've done .. creating an cursor and I've used it many times, hope it can help you.
--Declare all column names in table
DECLARE @Column1 decimal(9), @Column2 varchar(50), ect .....
DECLARE duplicate_curso r CURSOR FOR
-- select all columns in table bit you must have an count column
select Column1,Column2 , count(*) Cnt, ect ...
from tblTable
group...
Leave a comment: