T-SQL: Find Duplicates Without Using JOIN

I’d forgotten about this lil trick.

Chrissy is a Cloud and Datacenter Management & Data Platform MVP who has worked in IT for over 20 years. She is the creator of the popular SQL PowerShell module dbatools and holds a master's degree in Systems Engineering. Chrissy is also certified in SQL Server, Linux, SharePoint and network security. You can follow her on Twitter at @cl.

Posted in SQL Server
3 comments on “T-SQL: Find Duplicates Without Using JOIN
  1. LaptopHeaven says:

    why not use SELECT DISTINCT?

  2. Chrissy says:

    Because that does not solve the problem — I want to find duplicate records, not distinct records.

  3. Luv2Code says:


Leave a Reply

Your email address will not be published. Required fields are marked *