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

select distinct(a.salary)
from Salarydtls a
where 3= (select distinct(count(b.salary))
from salarydtls b
where a.salary<=b.salary)

ans is for third highest sal

Is This Answer Correct ?    0 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How to update multiple rows with one update statement in ms sql server?

1137


How do I view a trc file?

900


Define Joins?

976


What are the tools available in market as an alternative to sql server reporting services?

119


Define cursor locking

948


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

841


What is the difference between ‘having’ clause and a ‘where’ clause?

994


Explain about builtinadministrator?

989


Is it possible to have clustered index on separate drive from original table location?

908


What is SQL Azure Fabric?

108


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?

906


How to create a simple user defined function in ms sql server?

971


How to defragment indexes with alter index ... Reorganize?

1028


What is the difference between osql and query analyzer?

940


How to execute a sql statement using odbc_exec()?

1061