plsql dev
访问v$session,v$sesstat and v$statname视图的权限
grant create session,resource to chf;
grant
select
on
v_$session
to
chf;
grant
select
on
v_$sesstat
to
chf;
grant select on v_$statname to chf;
SELECT TABLE_NAME FROM USER_TAB_PRIVS;
SELECT C.NAME, B.STATISTIC#, B.VALUE
FROM V$SESSION A, V$SESSTAT B, V$STATNAME C
WHERE A.SID = B.SID
AND A.AUDSID = USERENV('SESSIONID')
AND B.STATISTIC# = C.STATISTIC#
ORDER BY C.STATISTIC#;