Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- select *,count(deptName) as total, sum(total) as totalnum ,empManager1 as ee,
- (select empFName from lrdc_org.employee where empID=ee) as managerfname, (select empLName from lrdc_org.employee where empID=ee) as managerlname from
- (lrdc_atm.assets a left join lrdc_atm.asset_details b on a.id=b.asset_id)
- left join (lrdc_org.employee c left join lrdc_org.dept d on c.deptID=d.id) on b.assignedTo=c.empSname
- group by empManager1
Add Comment
Please, Sign In to add comment