Friday, April 16, 2010

when the database has started (DBA_HIST_DATABASE_INSTANCE)

DBA_HIST_DATABASE_INSTANCE displays the databases and instances in the Workload Repository at the same time It has history on information such as instance startup time, last ASH sample id.especially startup time is very useful

DBID NUMBER NOT NULL Database ID

INSTANCE_NUMBER NUMBER NOT NULL Instance number
STARTUP_TIME TIMESTAMP(3) NOT NULL Startup time of the instance
PARALLEL VARCHAR2(3) NOT NULL Indicates whether the instance is running in a RAC environment (YES) or not (NO)
VERSION VARCHAR2(17) NOT NULL Database version
DB_NAME VARCHAR2(9) Name of the database
INSTANCE_NAME VARCHAR2(16) Name of the instance
HOST_NAME                     VARCHAR2(64) Name of the host
LAST_ASH_SAMPLE_ID NUMBER NOT NULL Last sample ID for the active session history

SELECT startup_time, last_ash_sample_id FROM dba_hist_database_instance order by startup_time;

No comments: