关于Struts2 + spring + hibernate进Q群: 130529143交流。
有偿技术支持Q群:398162181
创建角色-〉授予权限-〉分配给用户
--创建角色
create role my_role;
--给角色授予权限
grant create session, create table, create view to my_role;
--将权限授予用户
grant my_role to atguigu02;
--将其他用户的对象授权于指定用户(可以使用系统级用户,也可以是对象的拥有者)
grant select, update on scott.employees to atguigu
--将其他用户的对象授权于指定用户,
grant select on scott.depatments to atguigu with grant option;
--with grant option,获得该权限的用户具有授予给其他用户的权限
--具有授予的行为
grant select on scott.depatments to public;
--with grant option,所有用户都拥有该权限
创建控制用户权限
--创建用户(使用系统级帐户)
create user scott01 identified by scott01;
--给用户授权(使用系统级帐户,管理atguigu)
grant create session, create table to atguigu;
--为用户分配空间大小(使用系统级帐户)
alter user atguigu quota unlimited on users;
--修改用户名密码(使用本帐户就可修改,即自己可以改密码)
alter user atguigu identified by atguigu;
--收回对象权限
revoke select on scott.employees from atguigu;