| Sign In/My Account | View Cart |
| Article: |
SQL Data Types | |
| Subject: | Why doesn't the following query return me the nth highest value? | |
| Date: | 2005-07-28 07:34:41 | |
| From: | Suneel_Gundlapalli | |
|
select rownum,sal from (select distinct sal from emp order by sal desc) where rownum=&n;
|
||
Showing messages 1 through 1 of 1.
just replace = with < . u will definetly get the solution.actually rownum is assigned after retrieving the row.there lies the problem.
anyway u try this. u will get it