There is a 5000 EMP in company.how we find out the 5th
highest getting salary employee outof 5000 employes........
Answer Posted / nagireddy
select max(sal) from emp a where 5=(select count(distinct sal)
from emp b where a.sal<=b.sal);
| Is This Answer Correct ? | 13 Yes | 3 No |
Post New Answer View All Answers
What is blu acceleration in db2?
What is view db2?
Explain package in db2 and its advantages?
What is the use of dclgen in db2?
What is an instance in db2?
What is alias in db2?
What are sqlcodes –803,-805, -811, -818,-904,-911,-913,-101, +100?
I have a subprogram B calling from mainprogram A.I have opened a cursor in A ,Can i fetch the same cursor in subprogram B , If yes , Please explain the reason?
How to check table size in db2 sap?
What is copy pending status in db2?
What is null value in db2?
What is lock escalation in db2?
What is syscat in db2?
What is difference between isnull and coalesce?
How can you classify the locks in db2?