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 / harshal

Below query is written assuming table "employee" has a column called "salary".
select salary from (select salary from (select distinct(salary) from employee order by salary desc)where rownum<n) order by salary asc where rownum<1;

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How do I view views in sql server?

1059


What is the difference between createstatement and preparedstatement?

999


What is difference between cte and view?

975


What is SQL Server?

1271


What is the preferred way to create a clustered and non-clustered index? Which index should you create first the clustered or non-clustered?

961


What is the difference between implicit and explicit transaction?

1052


where can you add custom error messages to sql server? : Sql server administration

1173


What is primary key and example?

997


Explain concepts of analysis services?

1014


What is the difference between insensitive and scroll cursor?

1239


What is an indexing strategy?

1067


What is optimistic concurrency?

1091


What is the use of for clause?

1163


What is the command used to recompile the stored procedure at run time?

1119


What is check constraint in sql server?

1047