How to find top three highest salary in emp table in oracle

0 votes
How to find top three highest salary in emp table in oracle?
Sep 17, 2022 in Database by Kithuzzz
• 38,000 points
10,024 views

1 answer to this question.

0 votes

Use this:

SELECT  *FROM 
    (
    SELECT *FROM emp 
    ORDER BY Salary desc
    )
WHERE rownum <= 3
ORDER BY Salary ;

I hope this helps you.

answered Sep 18, 2022 by narikkadan
• 63,600 points

Related Questions In Database

0 votes
1 answer

How to find 3rd highest salary in SQL

select max(salary)from employeeposition where salary <(select max(salary)from employeeposition where ...READ MORE

answered Oct 27, 2023 in Database by anonymous

edited Mar 5 53,739 views
0 votes
1 answer

Which SQL query is used to find Nth highest salary from a salary table

If you want to find nth Salary ...READ MORE

answered Feb 14, 2022 in Database by Vaani
• 7,070 points
3,096 views
0 votes
1 answer

How to find third or nᵗʰ maximum salary from salary table?

Use ROW_NUMBER(if you want a single) or DENSE_RANK(for all ...READ MORE

answered Sep 19, 2022 in Database by narikkadan
• 63,600 points
1,228 views
0 votes
1 answer

How to load data of .csv file in MySQL Database Table?

At first, put the dataset in the ...READ MORE

answered Jul 5, 2019 in Database by Reshma
1,622 views
0 votes
1 answer

How to insert date values into table?

You have to convert the literal to ...READ MORE

answered Feb 18, 2022 in Database by Vaani
• 7,070 points
3,535 views
0 votes
1 answer

CASE .. WHEN expression in Oracle SQL

Use an IN clause. Example: SELECT status, CASE ...READ MORE

answered Sep 17, 2022 in Database by narikkadan
• 63,600 points
764 views
0 votes
1 answer

Automating Oracle script with nolio

Depending upon the details of your script ...READ MORE

answered Jul 17, 2018 in Other DevOps Questions by ajs3033
• 7,300 points
1,221 views
0 votes
1 answer

Is there any boolean type in Oracle database?

Nope. I don't think there is one But ...READ MORE

answered Oct 10, 2018 in Database by Neha
• 6,300 points
1,078 views
0 votes
0 answers

How to fetch the nth highest salary from a table without using TOP and sub-query?

I was recently requested to create a ...READ MORE

Aug 25, 2022 in Database by Kithuzzz
• 38,000 points
1,643 views
0 votes
0 answers

How to find sum of multiple columns in a table in SQL Server 2005?

I have a table Emp which has these rows: Emp_cd ...READ MORE

Aug 19, 2022 in Database by Kithuzzz
• 38,000 points
1,732 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP