Download(longops.sql)
REM +======================================================================+ REM REM File Name: longops.sql REM REM Description: REM Query To Monitor Longops Sessions REM REM Notes: REM Usage: sqlplus "/ as sysdba" @longops.sql REM REM +======================================================================+ Clear columns SET pages 100 SET Lines 280 COL MESSAGE for a40 WORD_WRAPPED COL START_TIME for a22 COL INST_ID for 99999 SELECT inst_id,SID, serial#, TO_CHAR (start_time, 'dd-MON-yyyy hh24:mi:ss') "START_TIME", ROUND (time_remaining / 60, 2) "TimeRemaining(M)", ROUND (elapsed_seconds / 60, 2) "ElapsedTime(M)" ,ROUND ((time_remaining + elapsed_seconds) / 60, 2) "TotalTime(M)", ROUND (sofar / totalwork * 100, 2) "%Complete", MESSAGE FROM gv$session_longops WHERE time_remaining > 0;
No comments:
Post a Comment