SELECT a.empno as emp_no,a.magno as manager_no,b.salary as 'emp_salary',c.salary as 'manager_salary'FROM (SELECT de.emp_no as empno ,dm.emp_no as magno FROM dept_emp as de JOIN dept_manager as dm ON de.dept_no = dm.dept_no AND de.emp_no <> dm.emp_no ...