Tuesday 25 February 2014

Redo log script

Redo log script to see how many in day.


 select to_char(first_time, 'DD-MON-YYYY'),
count(*)
from v$loghist
where first_time > '01-JAN-2010' /* or any other date that may be relevant */
Group by to_char(first_time, 'DD-MON-YYYY')
Order by count(*) asc;

==============================
==============================

select inst_id, to_char(completion_time, 'DD HH24') day_hour, count(*)
from gv$archived_log
where completion_time > sysdate - 7
group by inst_id, to_char(completion_time, 'DD HH24')
order by inst_id, to_char(completion_time, 'DD HH24')
/

No comments:

Post a Comment