title: Execute an Oracle Schedule-Program through an Oracle Schedule-Job
body: <p>I know that in order to schedule any action on a database table i must form a schedule chain, that is, a job (DBMS_SCHEDULER.CREATE_JOB) that links a schedule(DBMS_SCHEDULER.CREATE_SCHEDULE) and a program(DBMS_SCHEDULER.CREATE_PROGRAM). But what if i want to accomplish the same task only through a PROGRAM and a linked JOB ? Is it possible ? I have tried and when i check the PROGRAM log it shows me :</p>
  
  <pre><code>   RUNS      FAILS
  ======================
      10        10
  </code></pre>
  
  <p>Which means that the JOB has been executed for 10 times (runs at an interval of 5 secs.) and it has failed for the same number of times.</p>
  
  <p>Following are the codes for concerned JOB and PROGRAM :</p>
  
  <pre><code>PROGRAM-CODE :
  =================
  
  BEGIN
  SYS.DBMS_SCHEDULER.CREATE_PROGRAM
  (
    program_name         =&gt; 'HR.INSERT_PROG'
   ,program_type         =&gt; 'PLSQL_BLOCK'
   ,program_action       =&gt; 'insert into sch_test values (s1.nextval,s2.nextval)'
   ,number_of_arguments  =&gt; 0
   ,enabled              =&gt; TRUE
   ,comments             =&gt; NULL
  );
  END;
  
  
  JOB-CODE :
  ==========
  
  BEGIN
  SYS.DBMS_SCHEDULER.CREATE_JOB
  (
     job_name        =&gt; 'HR.JOB1'
    ,schedule_name   =&gt; 'HR.INSERT_SCH'
    ,program_name    =&gt; 'HR.INSERT_PROG'
    ,comments        =&gt; NULL
  );
  END;
  </code></pre>
  
  <p>The concerned table never gets populated. If anyone can tell me, what is it i am doing wrong here? Can this not be achieved without a SCHEDULE ?</p>