how to find the 2nd higgest salary in the column for example
take table name is employee?
And also find bottom 2nd lowest salary ?
Answer Posted / prasoon madnawat
SQL Server:
Select MIN(Salery) from (SELECT TOP 2 * from EMPLOYEE)
Oracle:
Select MIN(Salery) from (SELECT * from EMPLOYEE where ROWNUM <3)
MySQL
Select MIN(Salery) from (SELECT * from EMPLOYEE LIMIT 2)
| Is This Answer Correct ? | 0 Yes | 5 No |
Post New Answer View All Answers
Define cache? : Dot net architecture
what are login controls?
What are .net mobile controls features? : Microsoft dot net mobile
Explain a .net mobile example with details? : Microsoft dot net mobile
Explain How to improve the cache performance? : Dot net architecture
Explain the difference between inprocess vs out process session state : Dot net architecture
Explain the five stages in a dlx pipeline? : .NET Architecture
Session State and can i store desirialized object in state server, if yes how and if not why.
What is the mesi? : Dot net architecture
server.transfer limitation ?
What is the difference between machine config vs. Web config : Dot net architecture
how we can fire event in databound column in datagrid without using button?
What is the difference between .net mobile pages and ordinary .net web page? : Microsoft dot net mobile
How cache coherency is eliminated? : Dot net architecture
Can I create my own metadata attributes?