#创建用户
Create user ' lin ' @ ' localhost ' identified by ' 123 ';
#insert, Delele,update,select
#级别1: For all libraries, under all tables, under all fields
Grant SELECT On *. lin1 ' @ ' localhost ' identified by ' 123 ';
#级别2: All the fields under the DB1 library, under all tables,
Grant SELECT on db1.*-' lin2 ' @ ' localhost ' identified by ' 123 ';
#级别3: All fields below the table db1.t1
Grant SELECT on Db1.t1-' lin3 ' @ ' localhost ' identified by ' 123 ';
#级别4: Id,name field under Table Db1.t1
Grant Select (id,name) on db1.t1 to ' lin4 ' @ ' localhost ' identified by ' 123 ';
Grant Select (id,name), update (name) on db1.t1 to ' lin5 ' @ ' localhost ' identified by ' 123 ';
#修改完权限后, remember to refresh the permissions
Flush privileges;
LocalHost local host, identified by: Differential
Grant grants, Allow. Select Selection
Create user ' Panyu ' @ ' localhost ' identified by ' 123 '
Create user
Grant SELECT On * * to ' pan ' @ ' localhost ' identified by ' 123 '
Grant pan View permissions for all libraries and all fields
Grant SELECT on db1.* to ' yu ' @ ' localhost ' identified by ' 123 ';
Grant Yu to view all permissions for all tables under this library
Grant SELECT on Db1.t1 to ' Zhuge ' @ ' loaclhost ' identified by ' 123 ';
Grant Zhuge to view the fields in the DB1 library, below the T1 table.
Grant Select (id,name) on db1.t1 to ' guanyu ' @ ' localhost ' identified by ' 123 ';
Grang Select (id,name) update (name) on db1.t1 to ' Zhangfei ' @identified by ' 123 ';
mysql--Permissions Issues