题解 | #查看学校名称中含北京的用户#
获取员工其当前的薪水比其manager当前薪水还高的相关信息
http://www.nowcoder.com/practice/f858d74a030e48da8e0f69e21be63bef
select emp_salary.emp_no,emp_salary.manager_no,emp_salary.emp_s,salaries.salary from (select t1.emp_no,s.salary as emp_s,t1.dept_no,t1.manager_no as manager_no from (select de.emp_no,de.dept_no,dm.emp_no as manager_no from dept_emp de inner join dept_manager dm on de.dept_no=dm.dept_no) as t1 left join salaries s on t1.emp_no=s.emp_no)emp_salary left join salaries on emp_salary.manager_no=salaries.emp_no where emp_salary.emp_s > salaries.salary;