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 SQL query which should fetch the 5th maximum salary
of an employee from the table?

Answer Posted / vsandhyana

Hi Hashmatulla Baig,

I think your query will not give the desired output. it
should be modify please refer below for the same.

SELECT empno, sal
FROM
(
select empno, sal, (ROW_number() OVER (order by sal desc)) R
from emp
order by sal desc
)
WHERE R = 5;

Is This Answer Correct ?    4 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are all the advantages of Cognos?

1038


What are all the types of gateway used in Cognos?

1031


What is set to be cardinality?

1174


what is the use of backward drilling in cognos 8?is it possible?whats the uws of it?

2070


What is the deployment requirements used in cognos?

1655


Explain the different types of views used in cognos.

949


What is the use of powerplay web viewer in cognos?

1089


What is looping and how to avoid it in framework manager?

1207


What are the two types of framework manager?

1336


WHAT ARE THE DISTNICT VARIABLES?

2265


What is called materialized view?

1078


What are the types of security?

1029


What is the difference between low affinity and high affinity connections?

1019


How create measures and dimensions?

1077


difference between impromptu and cognos8

2443