我有以下过程,但没有创建调度程序作业,并且在运行作业时找不到任何错误。我该如何调试它以及代码有什么问题?
CREATE OR REPLACE PROCEDURE test
IS
prod_no varchar2(32);
prod_date date;
employee varchar2(32);
assurer varchar2(32);
prod_description varchar2(32);
prod_days number;
assig varchar2(32);
reg_no number;
l_v number;
BEGIN
prod_no := '300';
prod_date := sysdate;
employee := 'SAM';
assurer := 'MAT';
prod_description := 'test';
prod_days := 1;
assig := 'A';
reg_no := 1;
DBMS_SCHEDULER.create_job (
job_name => DBMS_SCHEDULER.generate_job_name ('FR'),
job_type => 'PLSQL_BLOCK',
job_action => 'BEGIN test_job('
|| i_prod_no
|| ','''
|| prod_date
|| ','''
|| employee
|| ','''
|| assurer
|| ','''
|| prod_description
|| ','''
|| prod_days
|| ','''
|| assig
|| ','''
|| reg_no
|| '''); end;',
start_date => SYSDATE,
end_date => NULL,
enabled => TRUE,
comments => 'test product'
);
commit;
exception
when others then
dbms_output.put_line (dbms_utility.format_error_stack);
END test;
/