2011-01-25

Oracle log switches per day

I just wrote this up to count the number of archived logs generated per day:
SELECT
  trunc(first_time) t,
  count(*)
FROM v$log_history
WHERE trunc(first_time) IN
  (SELECT DISTINCT
     trunc(first_time)
   FROM v$log_history)
GROUP BY trunc(first_time)
ORDER BY t;
There is probably an easier and faster way. Comments welcome.

Labels:

0 Comments:

Post a Comment

Subscribe to Post Comments [Atom]

<< Home