by Kevin Luckett (2 Submissions)
Category: Databases/Data Access/DAO/ADO
Compatability: VB 6.0
Difficulty: Unknown Difficulty
Originally Published: Thu 8th September 2005
Date Added: Mon 8th February 2021
Rating: (1 Votes)
This code always you to locate duplicates in SQL Server It has been tested using SQL Server 2000. It should work with all versions
select * from [Table Name] where [Column Name] in( select [Column Name] from
[Table Name] group by [Column Name]having Count(*) > 1)
Example:
select * from tbl_lot where lotid in ( select lotid from
tbl_lot group by lotid having Count(*) > 1)
No comments have been posted about This code always you to locate duplicates in SQL Server It has been tested using SQL Server 2000. I. Why not be the first to post a comment about This code always you to locate duplicates in SQL Server It has been tested using SQL Server 2000. I.