select * from table as a where exists(select 1 from table where name = a.name group by name having count(*) > 1)