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...

write a query for the fifth highest salary?

Answer Posted / piyush gupta

select distinct(a.sal) from emp a where 5=(select
count(distinct(b.sal)) from emp b where a.sal<=b.sal)


you can this query for nth highest salary
replace 5 with any number

Is This Answer Correct ?    2 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What will happen non-clustered index will be created on clustered index?

982


How is image stored in database?

984


how can we view column head in first page but not in remaining pages?

1987


query to Compare data of two tables between two different Databases(Oracle and SQL Server) Eg., Source Database: Oracle Table: Employee Target Database : SQL Server Table : emp

2006


What are the various ways to execute a query in teradata?

2543


A design problem was given in which I was supposed to make a design for the data base for a given problem.

1013


What is database server and how it works?

977


what are wrappers and build ups and what it's use?

2111


What is a database example?

919


Explain natural key?

1053


give a simple example of physical and logical data independence

2486


What is the difference between data source and database?

1009


define primary key index, bitmap index, hash index,virtual indwx

3277


What is database collection?

956


What is aws documentdb?

996