ALTER ANY PROCEDURE

CREATE ANY PROCEDURE

CREATE PROCEDURE

DEBUG ANY PROCEDURE

DROP ANY PROCEDURE

EXECUTE ANY PROCEDURE

只需要授予存储过程的DEBUG权限给某个用户,就可以实现只授予用户查看存储过程定义的权限,而限制用户修改、执行存储过程。从而达到只授权用户查看存储过程定义的权限。


--查看当前会话用户具有的角色权限;

select * from session_roles;

--查看当前用户具有的系统权限(包括角色权限附加的内容。)

select * from session_privs;



--移除权限

revoke DEBUG ANY PROCEDURE from search;

--删除数据库用户

DROP USER SEARCH CASCADE;

创建数据库用户

CREATE USER SEARCH IDENTIFIED BY search;

GRANT CONNECT TO SEARCH;

GRANT SELECT ANY TABLE TO SEARCH;

--1、查询用户会话信息:

select username, sid, serial#, machine from v$session WHERE USERNAME='SEARCH';

--删除用户会话信息:

Alter system kill session 'sid, serial#';


CREATE SESSION

CREATE TABLE

SELECT ANY TABLE

UPDATE ANY TABLE

CREATE CLUSTER

CREATE SEQUENCE

SELECT ANY SEQUENCE

CREATE PROCEDURE

CREATE ANY PROCEDURE

CREATE TRIGGER

CREATE TYPE

CREATE OPERATOR

CREATE INDEXTYPE

DEBUG ANY PROCEDURE


EXECUTE ANY TYPE

ALTER ANY PROCEDURE

--移除search用户的DBA角色

revoke dba from search