SQL(收藏)查询每一个部门工资前三名的员工信息

问:Oracle的EMP表,查询每一个部门工资前三名的员工信息,如何写?? 解答:(通用sql) select deptno, ename, sal from emp e1 where ( select count(1) from emp e2 where e2.deptno=e1.deptno and e2.sal>=e1.sal )
相关文章
相关标签/搜索