题解 | #查找当前薪水详情以及部门编号dept_no#

查找当前薪水详情以及部门编号dept_no

https://www.nowcoder.com/practice/c63c5b54d86e4c6d880e4834bfd70c3b

select
    a.emp_no as emp_no,
    a.salary as salary,
    a.from_date as from_date,
    a.to_date as to_date,
    b.dept_no as dept_no
from
    (
        select
            emp_no,
            salary,
            from_date,
            to_date
        from
            salaries
    ) a
    join (
        select
            dept_no,
            emp_no,
            to_date
        from
            dept_manager
    ) b
    on a.emp_no=b.emp_no

全部评论

相关推荐

求求给个offer我...:笑死了,笑完过了几分钟感觉挺可悲的
点赞 评论 收藏
分享
评论
点赞
收藏
分享

创作者周榜

更多
牛客网
牛客网在线编程
牛客网题解
牛客企业服务