|
Robert Freeman has more on the
gather_stats_job procedure.
Oracle Database 10g uses a scheduled job,
GATHER_STATS_JOB, to collect AWR
statistics. This job is created, and enabled
automatically when you create a new Oracle
database under Oracle Database 10g. To
see this job, use the
DBA_SCHEDULER_JOBS view as seen in this
example:
SELECT
a.job_name,
a.enabled,
c.window_name,
c.schedule_name,
c.start_date,
c.repeat_interval
FROM
dba_scheduler_jobs
a,
dba_scheduler_wingroup_members b,
dba_scheduler_windows
c
WHERE
job_name=’GATHER_STATS_JOB’
And
a.schedule_name=b.window_group_name
And
b.window_name=c.window_name;
You can disable this job using the
dbms_scheduler.disable procedure as seen
in this example:
Exec dbms_scheduler.disable(’GATHER_STATS_JOB’);
And you can enable the job using the
dbms_scheduler.enable procedure as seen
in this example:
Exec dbms_scheduler.enable(’GATHER_STATS_JOB’); |