Alternative solution
Hi, here is an alternative solution to this problem:
CREATE OR REPLACE VIEW v_avg_manager_salary AS
SELECT
ROUND(AVG(s.salary), 2)
FROM
salaries s
WHERE
s.emp_no IN (SELECT
m.emp_no
FROM
dept_manager m);
Is the solution provided better in any way?
Thanks.
1 answers ( 0 marked as helpful)
Hi Guillem!
Thanks for reaching out.
No, your solution is also valid.
Hope this helps.
Best,
Tsvetelin