REM REM Author: Mohit Dubey (Based on source from ixora) REM Visit http://www.geocities.com/md_seraphin for more goodies! REM REM This program is distributed under the GNU Public License Version 2 REM with the additional privisio that the original author's name and REM contact details must be retained as-is in any modified or copied REM versions of this program. REM -- Purpose: how many write batches have to wait for a log file sync? select decode( sum(w.total_waits), 0, 'NONE', to_char( nvl(100 * sum(l.total_waits) / sum(w.total_waits), 0), '99990.00' ) || '%' ) sync_waits from sys.v_$bgprocess b, sys.v_$session s, sys.v_$session_event l, sys.v_$session_event w where b.name like 'DBW_' and s.paddr = b.paddr and l.sid = s.sid and l.event = 'log file sync' and w.sid = s.sid and w.event = 'db file parallel write' /