how u can find the n row from a table?

Answer Posted / rishab

select emp_name,salary,rownum from
(select emp_name,salary,r from
(select salary,emp_name,rownum r from
(select salary,emp_name,rownum
from emp
order by salary desc)
order by r)
where r<4 ---- this number must be n+1
order by salary)
where rownum=1;
-- yes rownum=1 works...

Is This Answer Correct ?    4 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How do you declare a variable in pl sql?

535


What is primary key and unique key?

547


Is oracel sql developer written in java?

648


What is pl sql collection?

525


Can we update views in sql?

535






What is localdb mssqllocaldb?

621


How many rows can sqlite handle?

587


how can we optimize or increase the speed of a mysql select query? : Sql dba

506


what is 'mysqlshow'? : Sql dba

588


Why do we need view in sql?

547


What is lookup table in sql?

603


What is ttitle and btitle?

574


How would you pass hints to the sql processor?

530


how is myisam table stored? : Sql dba

605


How is data stored on a disk?

541