select e.id, e.name, e.salary from employee e where Exists (select * from employee a where e.employeeid = a.managerid)