| Subject: |
|
how do we find nth highest in SQL |
| Date: |
|
2005-10-17 23:29:32 |
| From: |
|
Apurva_Sharma
|
Response to: how do we find nth highest in SQL
|
Hi,
Solution to your query.Plz follow steps.
Steps
SQL> SET Verify OFF;
SQL> SELECT min(sal)
FROM (SELECT sal
FROM emp
order by sal desc)
WHERE rownum<(&nth_heighest+1);
|
Showing messages 1 through 3 of 3.
-
how do we find nth highest in SQL
2005-10-30 09:21:35
bhaskarreddy
[View]
-
how do we find nth highest in SQL
2006-10-17 02:09:39
Asha_S
[View]
-
how do we find nth highest in SQL
2010-05-11 00:05:08
vish44
[View]
if u want to print the second highest sal. replace 1 with 2.