Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Browse for duplicates
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00580628
Message ID:
00580649
Views:
24
>Well, I would like to define them as one field. Unfortunately it doesn't work that way. In this case I use the orgtracnum,date,amount,bankname to define the record. even then I have noticed that things don't go well. You know the real world. It's real.

No kidding!
SELECT orgtracnum,date,amount,bankname, COUNT (*) AS DupCount;
    FROM TableWithDupes ;
    GROUP BY 1,2,3,4 ;
    INTO CURSOR Dupes ;
    HAVING COUNT (*) > 1
That should get you the "key" values of what you consider to be duplicate entries.

A correlated subquery would be the way to get full information from each of the duplicate records. However, it's a bit tricky to formulate when you have a composite key, and I don't remember off the top of my head how I resolved that last time.

HTH,

Jay
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform