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

select * from emp where sal=(
SELECT DISTINCT (a.sal) FROM EMP A WHERE &N = (SELECT COUNT (DISTINCT (b.sal)) FROM EMP B WHERE a.sal<=b.sal));

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

if you encounter this kind of an error message, what you need to look into to solve this problem? : Sql server database administration

984


Does index speed up select statements?

1012


What is index, cluster index and nonclustered index?

995


What is the difference between having clause and where clause in sql server?

1100


What is a trigger what are the advantages of trigger?

1002


What are truncate options available in sql server? : sql server database administration

1034


Explain raiserror in sql server?

1029


How to retrieve error messages using odbc_errormsg()?

1058


What is inner join in sql server joins?

1035


What does it mean if @@cursor_row returns a negative number?

992


What is reportserver and reportservertempdb ?

152


Explain few examples of stored procedure over triggers?

1044


What is report snapshot in ssrs?

268


What are the system database in sql server 2005?

1044


What are translations and its use? : sql server analysis services, ssas

1040