@@header

/*
*
*  Author        : Vishal Gupta
*  Purpose       : Display DBMS Scheduler Jobs
*  Compatibility : 
*  Parameters    : NONE
*
*  Revision History:
*  ===================
*  Date       Author        Description
*  ---------  ------------  -----------------------------------------
*  23-May-13  Vishal Gupta  Created
*
*/


PROMPT **************************************************
PROMPT * DBMS Scheduler Jobs
PROMPT **************************************************

COLUMN job          HEADING  "Job"                FORMAT 9999
COLUMN broken       HEADING  "Broken"             FORMAT a1
COLUMN instance     HEADING  "I#"                 FORMAT 999
COLUMN last_date    HEADING  "LastRunTime"        FORMAT a18
COLUMN this_date    HEADING  "CurrentRunTime"     FORMAT a18
COLUMN next_date    HEADING  "NextRunTime"        FORMAT a18
COLUMN interval     HEADING  "Interval"           FORMAT a10
COLUMN failures     HEADING  "Failures"           FORMAT 99999
COLUMN what         HEADING  "What"               FORMAT a40

SELECT j.job
     , j.broken
     , j.instance
     , j.priv_user
     , TO_CHAR(j.last_date,'DD-MON-YY HH24:MI:SS') last_date
     , TO_CHAR(j.this_date,'DD-MON-YY HH24:MI:SS') this_date
     , TO_CHAR(j.next_date ,'DD-MON-YY HH24:MI:SS') next_date
     , j.interval
     , j.failures
     , j.what
  FROM dba_jobs j
;  

@@footer
