Table 'azmoon_azmo.v_imported_users' doesn't exist - select * from (select m.*, u.UserID as user_id, u.user_type,u.password,u.Name,u.Surname,u.email, 0 as imported from users u left join roles_rights rr on rr.role_id = u.user_type left join modules m on m.id= rr.module_id where u.UserName='' and disabled=0 and approved=1 and Password='' union select m.*, u.UserID as user_id, 2 as user_type,u.password,u.Name,u.Surname,u.email, 1 as imported from v_imported_users u left join roles_rights rr on rr.role_id = 2 left join modules m on m.id= rr.module_id where u.UserName='' and u.Password='' ) m order by priority