Home » SQL & PL/SQL » SQL & PL/SQL » query to find two highest salaries in each department
query to find two highest salaries in each department [message #623420] Wed, 10 September 2014 04:56 Go to next message
sujana123
Messages: 2
Registered: September 2014
Location: bangalore
Junior Member
Hi,

Can anyone please tell query to find two highest salaries in each department from Emp,Dept tables. Output should contain ename,dname,sal columns.

Thanks in advance.
Re: query to find two highest salaries in each department [message #623424 is a reply to message #623420] Wed, 10 September 2014 05:05 Go to previous messageGo to next message
Littlefoot
Messages: 21807
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
How does one select the TOP N rows from a table?
Re: query to find two highest salaries in each department [message #623429 is a reply to message #623420] Wed, 10 September 2014 05:29 Go to previous message
Michel Cadot
Messages: 68641
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator

As I told you in the topic you created in Test forum:

Michel Cadot wrote on Wed, 10 September 2014 08:15

The purpose of tis forum is to test your posts not to actually get an answer.
If this is a real question then post it in SQL & PL/SQL forum.
Before, Please read OraFAQ Forum Guide and How to use [code] tags and make your code easier to read.

Note that we don't give solution to homework but we can help you to achieve it if you show what you already tried and where you are stuck.
Also have a look at SQL FAQ.


Previous Topic: Help SUM
Next Topic: Replace strings before certain characters
Goto Forum:
  


Current Time: Sat Apr 20 05:13:41 CDT 2024