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 to find nth highest salary

Answer Posted / anonymous

select min(salary) from(
select salary from test
order by salary desc
)
where rownum<4



For ORACLE 8i,9i,10g


select distinct salary from
(select salary,
dense_rank() OVER (PARTITION BY empname ORDER BY salary
desc) rank
from test) where rank=7
;

Is This Answer Correct ?    3 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How to provide default values to stored procedure parameters?

1069


Your sql server is running out of disk space. You notice that there are several large files with ldf extensions what are these files?

1198


What is recursion? Is it possible for a stored procedure to call itself or recursive stored procedure? How many levels of sp nesting is possible?

968


when would you go for denormalization? : Sql server database administration

875


What is the rdl file?

139


What is lock escalation and what is its purpose?

978


What are synonyms?

965


What do you mean by an execution plan? Why is it used? How would you view it?

932


How do you delete a trigger?

988


how can you find out if the current user is a member of the specified microsoft® windows nt® group or microsoft sql server™ role? : Sql server administration

987


can SSRS reports Cache results?

149


List out some of the requirements to set up a sql server failover cluster?

1034


You schedule a job to run every minute what will happen if the first job runs more than 1 min? Will the second instance of the job start?

1040


If you're given a raw data table, how would perform etl (extract, transform, load) with sql to obtain the data in a desired format?

969


How to enter unicode character string literals in ms sql server?

1081