Oracle 视图 V$LOGHIST 官方解释,作用,如何使用详细说明
本站中文解释
的用途和使用
Oracle V$LOGHIST视图主要用于查询有关日志归档历史信息的信息,并可将其显示在控制台或者脚本中。V$LOGHIST视图可以查询归档日志数量、归档日志文件名、归档时间、归档内容和每块归档日志的尺寸、SCN和更新时间等等,提供了有关数据库日志信息的完整信息。
使用示例:
查询最近的5块归档日志文件的归档时间:
SELECT TO_CHAR(FIRST_TIME, ‘YYYY-MM-DD HH24:MI:SS’) FIRST_TIME, SEQUENCE#, THREAD#
FROM V$LOGHIST
ORDER BY SEQUENCE# DESC
WHERE SEQUENCE#
官方英文解释
V$LOGHIST
contains log history information from the control file. This view is retained for historical compatibility. Oracle recommends that you use V$LOG_HISTORY
instead.
See Also:
“V$LOG_HISTORY”
Column | Datatype | Description |
---|---|---|
|
|
Log thread number |
|
|
Log sequence number |
|
|
Lowest SCN in the log |
|
|
Time of first SCN in the log |
|
|
SCN at which the log switch occurred; one more than highest SCN in the log |
|
|
The ID of the container to which the data pertains. Possible values include:
|