use mysql; grant select, insert, delete, update on testege.* to 'admin'@'localhost' identified by 'teacher_pwd'; grant lock tables on testege.* to 'admin'@'localhost'; grant process on *.* to 'admin'@'localhost'; grant usage on *.* to 'student'@'localhost' identified by '12345'; grant select on testege.* to 'student'@'localhost'; grant lock tables on testege.* to 'student'@'localhost'; grant insert on testege.person to 'student'@'localhost'; grant insert on testege.result to 'student'@'localhost'; grant insert, update, delete on testege.answers to 'student'@'localhost';