Untitled
Anonymous
plain_text
11/28/2021 7:42 PM
632 B
25
Indexable
SELECT c.company_code, c.founder, (SELECT count(DISTINCT lead_manager_code) FROM Lead_Manager l where l.company_code = c.company_code), (SELECT count(DISTINCT senior_manager_code) FROM Senior_Manager s where s.company_code = c.company_code), (SELECT count(DISTINCT manager_code) FROM Manager m where m.company_code = c.company_code), (SELECT count(DISTINCT employee_code) FROM Employee e where e.company_code = c.company_code) FROM Company c ORDER by c.company_code;
Editor is loading...