How to grant permissions to users based on table information?
Something like that could be achieved through dynamic sql, or via using stored procedures instead of views (for selecting) or triggers (for controlling inserts/updates).alter

But you can also create the memberview to return values according to the currently logged on user, which is probably more practical:

create view memberview as 
  select Dept, Name 
  from Employees
  where Dept= (
    select Dept
    from Employees
    where Name = coalesce(nullif(mid(current_user, 1, locate('@', current_user)-1), ''), current_user)
    );