字典
作者:互联网
锁,enqueue
select * from dba_lock;
select * from dba_lock_internal;
---------------------------------------
统计
select * from v$sysstat;
--会话断开,所有的统计在sysstat中更新
select * from v$sysstat order by class;
select * from v$sysstat where class="64" order by name;
select * from v$sysstat where statistic# between 633 and 635;
select * from v$session where type='USER' order by sid;
select * from v$session where username='KYC_ACC';
--找出一个会话id,sid
select * from v$sesstat;
--再在一个sid对应679个统计名
select sid from v$sesstat group by sid;
select * from v$sesstat where sid=16;
select * from v$statname;
--加字段,以便信息更全
SELECT
a1.*,
a2.name,
a3.schemaname
FROM
v$sesstat a1
LEFT JOIN v$statname a2 ON a1.statistic# = a2.statistic#
left join v$session a3 on a1.sid=a3.sid
WHERE
a1.sid = 16;
-------------------------------------------
标签:--,sysstat,a1,sid,where,select,字典 来源: https://www.cnblogs.com/createyuan/p/13973053.html