Oracle 视图 DBA_HIST_SESS_TIME_STATS 官方解释,作用,如何使用详细说明
本站中文解释
Oracle视图DBA_HIST_SESS_TIME_STATS用于显示会话操作消耗的时间统计信息,对数据库中每次会话执行记录中每个步骤执行消耗时间的累计信息,可以统计出某次会话执行每步骤耗时。
使用方法
1、在Oracle数据库控制台中,使用以下SQL语句查看当前会话操作耗时:
SELECT SQL_ID,SESSION_ID,SESSION_SERIAL#,EVENT,TIME_WAITED
FROM DBA_HIST_SESS_TIME_STATS
WHERE TIME_WAITED > 0
2、使用以下SQL语句可以查看一段时间内某个会话的操作耗时:
SELECT SQL_ID,SESSION_ID,SESSION_SERIAL#,EVENT,TIME_WAITED,SAMPLE_TIME
FROM DBA_HIST_SESS_TIME_STATS
WHERE SESSION_ID= AND SAMPLE_TIME > to_date(‘20200101′,’yyyymmdd’);
官方英文解释
DBA_HIST_SESS_TIME_STATS
displays information about CPU and I/O time for interesting Oracle GoldenGate and XStream sessions.
Column | Datatype | NULL | Description |
---|---|---|---|
|
|
|
Unique snapshot ID |
|
|
|
Database ID for the snapshot |
|
|
|
Instance number for the snapshot |
|
|
|
Type of session |
|
|
Minimum logon time |
|
|
|
Total CPU time |
|
|
|
Total system I/O wait time |
|
|
|
Total user I/O wait time |
|
|
|
The database ID of the PDB for the sampled session |
|
|
|
|
Session module. Valid values:
|
|
|
The ID of the container that
|