I need to query a table for duplicate deposit records, where two deposits made at one cash terminal, for the same amount, within a certain time window, are considered duplicate records. I’ve started working on a query now, but I would appreciate any advice or suggestions on doing this ‘properly’.
Share
Generally, you’d do a self join to the same table, and put your “duplicate” criteria in the join conditions.
E.g.