Hi, SQL experts,
I need help. I want to like top 5 employees with highest salary for each department. For example, we have 3 departments A, B, and C. I would like to have:
Deparment A:
emp1 $100,000
emp2 $99,000
emp3 $98,200
emp4 $89,999
emp5 $85,300
Deparment B:
emp6 $120,000
emp7 $100,900
emp8 $98,000
emp9 $97,000
emp10 $89,900
Deparment C:
emp11 $45,000
emp12 $35,999
emp13 $35,900
emp14 $34,000
emp15 $30,000
Thanks a lot for any help.
I need help. I want to like top 5 employees with highest salary for each department. For example, we have 3 departments A, B, and C. I would like to have:
Deparment A:
emp1 $100,000
emp2 $99,000
emp3 $98,200
emp4 $89,999
emp5 $85,300
Deparment B:
emp6 $120,000
emp7 $100,900
emp8 $98,000
emp9 $97,000
emp10 $89,900
Deparment C:
emp11 $45,000
emp12 $35,999
emp13 $35,900
emp14 $34,000
emp15 $30,000
Thanks a lot for any help.