DBAsupport.com Forums - Powered by vBulletin
Results 1 to 3 of 3

Thread: Query on DBMS_JOB

  1. #1
    Join Date
    Jan 2001
    Posts
    14

    Question

    Please tell me how to create DBMS_JOB?

    I have tried the following:
    to execute the procedure 'procedure_name' every 1/2 hour as an admin user.


    SQL> variable jobno NUMBER;
    SQL>begin
    >DBMS_JOB.SUBMIT(:jobno,'procedure_name',sysdate,'sysdate+24/48');
    >end;

    It gave error: ORA:00900.

    what is the problem with the syntax?

    I have tried

    exec DBMS_JOB.SUBMIT(:jobno,'procedure_name',sysdate,'sysdate+1');

    also.

    Please suggest me exact syntax and any settings to be done.

  2. #2
    Join Date
    Jul 2000
    Posts
    296
    Semicolon (';') in what parameter is missing.
    And it you want to run it every 1/2 hour, the interval should be 1/48, not 24/48=1/2, is every 12 hours.
    SQL> variable jobno NUMBER;
    SQL>begin
    >DBMS_JOB.SUBMIT(:jobno,'procedure_name;',sysdate,'sysdate+1/48');
    >end;





  3. #3
    Join Date
    Jan 2001
    Posts
    14

    Smile

    thanks, it works.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Click Here to Expand Forum to Full Width