Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

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 subquery works in sql?

1128


What is input buffer in sql*plus?

1292


what is difference between delete and truncate commands? : Sql dba

1170


what is the difference difference between procedure and packages

10539


Advantages and disadvantages of stored procedure?

1166


How can you select unique records from a table?

1146


Can dml statements be used in pl/sql?

1123


How do I remove duplicates in two columns?

1147


explain the difference between delete , truncate and drop commands? : Sql dba

1146


How does postgresql compare to oracle/db2/ms sql server/informix?

1093


What is natural join in sql?

1044


What is a nested table in word?

1009


What is the difference between local variables and global variables?

1174


What is pl sql and why it is used for?

1156


What is the trigger in sql?

1001