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
What is a Query Subject?
What is called cognos reporting tool?
how can you get the errors in job? when loops are araised we get error?
What is difference between primary key and unique key constraints?
Write some methods to apply securities in framework manager model?
What is a Cube?
What is difference between page break and section report?
What are the different uses of a repository manager?
which type of project we r going to snowflake schema
hi friends pls forward impropmtu interview question
What's the limitation of 'Page Footer' in Report Studio? e.g. If I have an activity prompt (list of activities in a Search & Select Prompt) and selected around 2500 activites from the 'Activity' Search & Select Prompt and when I ran the report I got a message "#! Overflow" in page footer. Can somebody please tell me what's max. limit. I tried with around 300 activities and page footer displayed the activities. Your help will be appriciated.
write a query to display the departments with no employee?
how u burst the reports? if u r bursted reports is not reached to destination how u identify???
what is the difference between querystudio in reportnet and cognos8
Diff b/w Crossproduct and Outerjoin?