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 get employee name from employee table which is the
fiveth highest salary of the table

Answer Posted / a g srikanth

Dear Shiv Shankar
There is a small mistake in your query

Select Salary From Employee a Where 5=(
Select Count(Distinct Salary) From Employee b
Where a.Salary <= b.Salary )

the correct one should be

Select Salary From Employee a Where 5=(
Select Count(Distinct Salary) From Employee b
Where a.Salary >= b.Salary )

please check it...

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are three advantages to using sql?

1072


Does sql require a server?

1056


Which one is faster ienumerable or iqueryable?

992


How would you pass hints to the sql processor?

1041


how to check server status with 'mysqladmin'? : Sql dba

1134


What are the advantages of stored procedure?

1043


How do you modify a table in sql?

1166


What does desc stand for?

1125


What does a pl/sql package consist of?

1019


What are the different parts of a package?

1155


How does left join work in sql?

1041


How do I view an execution plan in sql?

1036


what is the difference between cluster and non cluster index? : Sql dba

1080


Do triggers have restrictions on the usage of large datatypes, such as long and long raw?

1226


Explain raise_application_error.

1145