How to find multiple/duplicate rows with the same value

Just a short SQL script which will allow you to find mutiple rows with same values in a table. Since its a very straightforward query, it needs no further explanation :)

[sql]

select [column_name]
from [tablename]
group by [column_name]
having count(*) > 1
— � OR

Select * from [TableName] where [ColumnName] IN (
select [ColumnName] from (
select count([ColumnName]) as N, [ColumnName] from [TableName]
— Where Clause If needed
group by [ColumnName]
)a
where N > 1
)

[/sql]

There is a similar article which describes more techniques to follow for managing duplicate rows from a table .

http://support.microsoft.com/kb/139444