Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

unable to get DDL of Scheduler Jobs

JhilOct 24 2019 — edited Nov 12 2019

Hj Experts,

I am unable to get DDL of Scheduler jobs ,

FYI  => I just changed job_name and schema name (just dummy names is pasted following below)

SQL> select job_name, job_type,auto_drop,last_start_date, state,owner from all_scheduler_jobs
  2  where job_name=JOB1';

JOB_NAME                                 JOB_TYPE         AUTO_ LAST_START_DATE                            STATE                OWNER
---------------------------------------- ---------------- ----- ------------------------------------------ -------------------- ------------
JOB1                             FALSE 24-OCT-19 07.07.43.499000 PM GMT           SCHEDULED            SCHEMA1

Error is here

-------------------

SQL> select dbms_metadata.get_ddl('PROCOBJ', 'JOB1','SCHEMA1') from dual;
ERROR:
ORA-31603: object "JOB1" of type PROCOBJ not found in schema SCHEMA1"
ORA-06512: at "SYS.DBMS_METADATA", line 6478
ORA-06512: at "SYS.DBMS_SYS_ERROR", line 105
ORA-06512: at "SYS.DBMS_METADATA", line 6465
ORA-06512: at "SYS.DBMS_METADATA", line 9202
ORA-06512: at line 1

no rows selected

DB : 12.2

This post has been answered by Gaz in Oz on Nov 7 2019
Jump to Answer
Comments
Post Details
Added on Oct 24 2019
24 comments
3,621 views