declare @t table(id int,name varchar(10))
insert into @t
select '1','a' union all
select '1','b' union all
select '1','c' union all
select '2','e' union all
select '3','f' union all
select '3','g'
------------------------------
select * from
(select id from @t
group by id having count(*)>1) a
left join @t b
on a.id=b.id
id id name
----------- ----------- ----------
1 1 a
1 1 b
1 1 c
3 3 f
3 3 g