I Have Employee table having column name as ID,SALARY
how to get second max salary from employee table with id
ex
ID SALARY
1 20000
7 37000
2 5000
Answer Posted / bennison terry
Select Top 1 * from Tbl_Salary where ID not in (Select top 1 ID from tbl_salary order by salary desc) order by Id desc
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
Define inner join? Explain with an example?
Do you know how to make remote connection in database?
What are user defined functions in ms sql server?
How will you decide the active and passive nodes?
what types of replication are supported in sql server? : Sql server database administration
how to use DTS package in 2000,2005,2008 in sql server
How do you create a data source?
Which language rdl files made of?
What are the common performance issues in sql server?
How can we migrate from SQL server to SQL Azure?
What options are available to audit login activity? : sql server security
How many triggers you can have on a table?
How to create an identity column?
State the difference between union and union all?
Explain insert into select statement?