MySQL - Using JOIN and WHERE to determine average hours

前端 未结 4 1213
死守一世寂寞
死守一世寂寞 2021-01-22 13:15

I am learning MySQL using a next.tech course that relies on the following schema:

My current task is to find the average number of hours worked on one specific

4条回答
  •  北海茫月
    2021-01-22 13:57

    You need specific wich join you using, there's INNER,LEFT,RIGHT,FULL,OUTER So try these

    SELECT AVG(hours) FROM project_employees
    INNER JOIN  projects
    ON  project_employees.employee_id = projects.id
    WHERE name = 'Washington Avenue Barber';
    

提交回复
热议问题