Average salary of managers
Hello,
I thought the assignment would be similar in thought with the lecture, where we took the MAX() of from_date and to_date columns, so that only one emp_no would be visible. Shouldn't we take that into consideration when we compute the average salary of managers? Technically they are receiving the most recent salary only, unless what we wanted was to take the average salary of employees with emp_no pertaining to managers.
Or maybe I got confused when the assignment stated "the average salary of all managers registered in the database", which I thought we only take the average of 24 salaries.
Best,
Carl
Hi Carl!
Thanks for reaching out.
Yes, we need to use these 24 managers but they have different periods of work for the company and have more than 24 salaries. So, we need to use the three tables - dept_manager, salaries and departments.
Hope this helps.
Best,
Tsvetelin