Try this:DECLARE @MyTable table (MyNameColumn varchar(100) collate SQL_Latin1_General_CP1_CI_AS);INSERT @MyTable values ('bill');INSERT @MyTable values ('Bill');INSERT @MyTable values ('BILL');INSERT @MyTable values ('BILL');INSERT @MyTable values ('Sue');INSERT @MyTable values ('Sue');INSERT @MyTable values ('John');INSERT @MyTable values ('Dan');INSERT @MyTable values ('DAN');INSERT @MyTable values ('Ralph');WITH CTE1AS(SELECT MyNameColumn, COUNT(*) OVER(PARTITION BY MyNameColumn) AS CntFROM @MyTableGROUP BY MyNameColumn, CONVERT(VARBINARY(100),MyNameColumn))SELECT MyNameColumnFROM CTE1WHERE cnt > 1/* -- outputMyNameColumnBILLBillbillDANDan*/
It gets a distinct list of names that have different cases within the dataset. You can expand this concept as needed.