Advertisement

SQL: 570. 至少有五位直接下属的经理 SQL: 570. 至少有五位直接下属的经理

阅读量:

数据

复制代码
    drop table if exists Employee;
    Create table If Not Exists Employee (Id int, Name varchar(255), Department varchar(255), ManagerId int);
    Truncate table Employee;
    insert into Employee (Id, Name, Department, ManagerId) values ('101', 'John', 'A', null);
    insert into Employee (Id, Name, Department, ManagerId) values ('102', 'Dan', 'A', '101');
    insert into Employee (Id, Name, Department, ManagerId) values ('103', 'James', 'A', '101');
    insert into Employee (Id, Name, Department, ManagerId) values ('104', 'Amy', 'A', '101');
    insert into Employee (Id, Name,

全部评论 (0)

还没有任何评论哟~