This article mainly introduces the Code related to Oracle job information to show you how to view Oracle job information. If you are puzzled by the actual application of Oracle job information, you may wish to browse the following articles and hope that you can get what you want.
View Oracle job information
1. Related views
- dba_jobs
- all_jobs
- user_jobs
- dba_jobs_running
Including running Oracle Job Information
2. View related information
- SQL>SELECT JOB, NEXT_DATE, NEXT_SEC, FAILURES, BROKEN
- SQL>FROM DBA_JOBS;
- JOB NEXT_DATE NEXT_SEC FAILURES B
- 9125 01-JUN-01 00:00:00 4 N
- 14144 24-OCT-01 16:35:35 0 N
- 9127 01-JUN-01 00:00:00 16 Y
- 3 rows selected.
Information about running jobs
- SELECT SID, r.JOB, LOG_USER, r.THIS_DATE, r.THIS_SEC
- FROM DBA_JOBS_RUNNING r, DBA_JOBS j
- WHERE r.JOB = j.JOB;
- SID JOB LOG_USER THIS_DATE THIS_SEC
- 12 14144 HR 24-OCT-94 17:21:24
- 25 8536 QS 24-OCT-94 16:45:12
- 2 rows selected.
Job queue lock Information
- SELECT SID, TYPE, ID1, ID2
- FROM V$LOCK
- WHERE TYPE = ’JQ’;
- SID TY ID1 ID2
- 12 JQ 0 14144
- 1 row selected.
The above content is an introduction to how to view the relevant Oracle job information.