Hi,
I have a table A which has four rows as follows
Table A
-------
empname salary
------- ------
A 1000
B 2000
C 3000
A 1000
B 2000
D 5000
I need the following output:
empname salary
------- ------
A 1000
A 1000
B 2000
B 2000
Thanks in advance
Answer Posted / murtaza
select empname,salary from A
where empname IN ('A','B');
Is This Answer Correct ? | 3 Yes | 2 No |
Post New Answer View All Answers
How to view existing indexes on an given table using sys.indexes?
Equi join and non equi join is possible with sql server?
What is the purpose of indexing?
Give me a SQL Query to find out the second largest company?
plss anybody specify tha constrian management system in dbms
How will you decide the active and passive nodes?
What is the difference between clustered index and primary key?
How to fetch the next row from a cursor with a "fetch" statement?
What is the report model project?
What is usually the first word in a sql query?
Can we use custom code in ssrs?
Can a database be shrunk to 0 bytes, if not, why?
What is inline table-value user-defined function?
What does the on delete cascade option do?
Do comments need to go in a special place in sql server 2005?