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 / vijendra singh shakya
For Employee table plz use the following Query...
select [empid] from employee group by [empid]
having count(empid)>1
| Is This Answer Correct ? | 17 Yes | 0 No |
Post New Answer View All Answers
Does partitioning help performance?
How to declare and use cursor variables?
What are triggers in ms sql server?
How to enter date and time literals in ms sql server?
What is the new security features added in sql server 2014? : sql server security
What is the security principal at the database level that represents your session?
What is the difference between set and select?
How to use subqueries with the exists operators in ms sql server?
How to select true false based on column value in sql server?
What are the differences between substr and charindex in sql server.
What is an example of a foreign key?
How to modify the underlying query of an existing view?
What action plan is preferred if sql server is not responding?
last function used in MS Access to convert sql what function will use in sql
Explain what is use of dbcc commands?