How to find the second largest salary in the emp database and
also How to find 3rd,4th and so on ........ in the emp database
plz mail the answer @ mak2786@gmail.com
Answer Posted / amar banerjee
sol1> select MAX(salary) from emp where salary< (select MAX(salary) from emp);
sol2> select salary from emp sort by salary desc limit 1,1;
for finding nth position
select salary from emp sort by salary desc limit n-1,1;
| Is This Answer Correct ? | 4 Yes | 2 No |
Post New Answer View All Answers
Which tools are available to manage SQL Azure databases and servers?
What is trigger explain with program?
Explain the relational database management system (rdbms)?
What is inner join? Explain with an example?
Find columns used in stored procedure?
Do you know what is similarity and difference between truncate and delete in sql?
Does sql server 2000 clustering support load balancing?
List all types of constraints in sql server?
Which data type columns are the best candidates for full-text indexing?
How will you decide the active and passive nodes?
Why do we use stored procedures in sql server?
What is a constant or literal in ms sql server?
How do you manipulate data?
What is the difference between web edition and business edition?
What is database replication?