SELECT s.last_name AS employee_last_name,
ss.reports_to AS manager_last_name
FROM staff AS s
LEFT JOIN staff AS ss ON s.employee_id=ss.reports_to
GROUP BY 1, 2
SELECT DISTINCT s.last_name AS employee_last_name,
ss.reports_to AS manager_last_name
FROM staff AS s
LEFT JOIN staff AS ss ON s.employee_id=ss.reports_to
Re: Re: task 4
From Blush Motmot, 6 Months ago, written in Plain Text, viewed 168 times.
This paste is a reply to Re: task 4 from Ivory Tortoise
- go back
URL http://codebin.org/view/f277c979/diff
Embed
Viewing differences between Re: task 4 and Re: Re: task 4
— Expand Paste to full width of browser