您的位置:首页 > 数据库 > Oracle

Oracle 创建普通用户,并赋予权限

2017-10-26 15:57 405 查看
Oracle 创建普通用户,并赋予权限

1) 采用sys or system / manager as sysdba; 连接数据库。

2) 创建普通用户peng: create user peng identified by pwd_oracle;
删除用户, drop user peng;

3) 授予用户登录数据库的权限: grant create session to peng;

4) 授予用户操作表空间的权限:
grant unlimited tablespace to peng;
grant create tablespace to peng;
grant alter tablespace to peng;
grant drop tablespace to peng;
grant manage tablespace to peng;

5) 授予用户操作表的权限:
grant create table to peng; (包含有create index权限, alter table, drop table权限)

6) 授予用户操作视图的权限:
grant create view to peng; (包含有alter view, drop view权限)

7) 授予用户操作触发器的权限:
grant create trigger to peng; (包含有alter trigger, drop trigger权限)

8) 授予用户操作存储过程的权限:
grant create procedure to peng;(包含有alter procedure, drop procedure 和function 以及 package权限)

9) 授予用户操作序列的权限:
grant create sequence to peng; (包含有创建、修改、删除以及选择序列)

10) 授予用户回退段权限:
grant create rollback segment to peng;
grant alter rollback segment to peng;
grant drop rollback segment to peng;

11) 授予用户同义词权限:
grant create synonym to peng;(包含drop synonym权限)
grant create public synonym to peng;
grant drop public synonym to peng;

12) 授予用户关于用户的权限:
grant create user to peng;
grant alter user to peng;
grant become user to peng;
grant drop user to peng;

13) 授予用户关于角色的权限:
grant create role to peng;

14) 授予用户操作概要文件的权限
grant create profile to peng;
grant alter profile to peng;
grant drop profile to peng;

15) 允许从sys用户所拥有的数据字典表中进行选择
grant select any dictionary to peng;
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签:  Oracle 创建 普通用户