,A.AnnualLeaveDay, A.DirectSupervisor,A.OpenId,A.ActivationStatus,IFNULL(B.MName,'') AS AccountName,B.MHead AS UserIcon,B.Dept_Id,B.Post_Id,IFNULL(B.Email,'') AS Email
,A.AnnualLeaveDay, A.DirectSupervisor,A.OpenId,A.ActivationStatus,IFNULL(B.MName,'') AS AccountName,B.MHead AS UserIcon,B.Dept_Id,B.Post_Id,IFNULL(B.Email,'') AS Email
FROM rb_account AS A INNER JOIN rb_manager AS B ON A.AccountId=B.MId AND A.AccountType=1
FROM rb_account AS A INNER JOIN rb_manager AS B ON A.AccountId=B.MId AND A.AccountType=1
,A.AnnualLeaveDay, A.DirectSupervisor,A.OpenId,A.ActivationStatus,IFNULL(B.TeacherName,'') AS AccountName,B.TeacherIcon AS UserIcon,B.Dept_Id,B.Post_Id,IFNULL(B.Email,'') AS Email
,A.AnnualLeaveDay, A.DirectSupervisor,A.OpenId,A.ActivationStatus,IFNULL(B.TeacherName,'') AS AccountName,B.TeacherIcon AS UserIcon,B.Dept_Id,B.Post_Id,IFNULL(B.Email,'') AS Email
FROM rb_account AS A INNER JOIN rb_teacher AS B ON A.AccountId=B.TId AND A.AccountType=2
FROM rb_account AS A INNER JOIN rb_teacher AS B ON A.AccountId=B.TId AND A.AccountType=2
,A.AnnualLeaveDay, A.DirectSupervisor,A.OpenId,A.ActivationStatus,IFNULL(B.AssistName,'') AS AccountName,B.AssistIcon AS UserIcon,B.Dept_Id,B.Post_Id,IFNULL(B.Email,'') AS Email
,A.AnnualLeaveDay, A.DirectSupervisor,A.OpenId,A.ActivationStatus,IFNULL(B.AssistName,'') AS AccountName,B.AssistIcon AS UserIcon,B.Dept_Id,B.Post_Id,IFNULL(B.Email,'') AS Email
FROM rb_account AS A INNER JOIN rb_assist AS B ON A.AccountId=B.AId AND A.AccountType=3
FROM rb_account AS A INNER JOIN rb_assist AS B ON A.AccountId=B.AId AND A.AccountType=3