[progress Communities] [progress Openedge Abl] Forum Post: Re: Removing Duplicates From A Table

Status
Not open for further replies.
P

Patrick Tingen

Guest
How can you have duplicates if the pk is not the same? It's part of the table as well as the rest of the data. If - and I am starting to assume here - you have a synthetic key (a single integer) and all the rest is the same, then something along this lines should do the trick: for each break by by by ... by : if not first-of( ) then delete . end. The idea is to do a break-by on all fields except the primary index field. Then, if you find a duplicate, delete it. This may not work if your table is large though.

Continue reading...
 
Status
Not open for further replies.
Top