DBMS_JOB.RUN error ORA-06512: at "SYS.DBMS_IJOB", line 548
We have a user in one of our companies getting the following error when trying to run a job. Can anyone offer suggestions? A similar job that analyzes tables runs fine in another database this company owns. And its not the analyze that's failing because he can successfully execute the analyze outside of a scheduled job.
--------------------- error -----------------------------------
@job_run_prc
BEGIN
*
ERROR at line 1:
ORA-12011: execution of 1 jobs failed
ORA-06512: at "SYS.DBMS_IJOB", line 548
ORA-06512: at "SYS.DBMS_JOB", line 278
ORA-06512: at line 2
------------------ job_run_prc -----------
job_run_prc is script as follows:
BEGIN
DBMS_JOB.RUN(42);
END;
/
-------------------- background ------------------------------
The user can not run the job with the dbms_job.run he gets the above error messages. The job runs the lr_analyze_tables_prc. However, from the sql prompt the user can successful execute lr_analyze_tables_prc with:
EXEC lr_analyze_tables_prc
PL/SQL procedure successfully completed.
The lr_analyze_tables_prc is as follows:
procedure lr_analyze_tables_prc as
BEGIN
DBMS_UTILITY.ANALYZE_SCHEMA('USG_SHARED','COMPUTE',0,0);
END lr_analyze_tables_prc;