employee table has employee id
-----------
empid
----------------
1
2
3
3
3
4
5
5
5
6
6
6
7
here the values r repeated two times.how to select the
repeated values only.i.e 3,5,6 should alone come.
Answer Posted / rajesh kumar
select empid from employee where empid in (select empid
from employee group by empid having count(empid) > 1)
| Is This Answer Correct ? | 0 Yes | 1 No |
Post New Answer View All Answers
How to enter comments in transact-sql statements?
How do you handle datasets larger than 50 gb?
What are distributed partitioned views?
What is attribute hierarchy? : sql server analysis services, ssas
Why and when do stored procedure recompile?
What do you mean by 'normalization'?
Explain the concept of view and Types of views in SQL server?
What is transactional replication?
Is there any difference between the primary key and unique key?
What are different types of schemas?
Explain a join?
Name few endpoints exposed by ssrs 2012?
What is a hint?
What is RMS migrations?
What are the database objects? : SQL Server Architecture