Home » SQL & PL/SQL » SQL & PL/SQL » execute a procedure automatically (oracle 9i)
execute a procedure automatically [message #434322] Tue, 08 December 2009 11:43 Go to next message
mohaninforakle
Messages: 55
Registered: January 2009
Member
hai every body,

I have a problem of executing a procedure automatically for a specific time interval,first i created a procedure then i assigned into a dbms job as to run it automatically,i want the procedure to run automatically for every 5 minutes but the job which i created does not run the procedure.Please help me how to run a procedure with the help of dbms_job and its scheduler.
Re: execute a procedure automatically [message #434324 is a reply to message #434322] Tue, 08 December 2009 11:50 Go to previous messageGo to next message
BlackSwan
Messages: 24905
Registered: January 2009
Senior Member
>I have a problem of executing a procedure automatically for a specific time interval,first i created a procedure then i assigned into a dbms job as to run it automatically,
>i want the procedure to run automatically for every 5 minutes but the job which i created does not run the procedure.Please help me how to run a procedure with the help of dbms_job and its scheduler.

post CUT & PASTE showing how you concluded job not run.

Did you COMMIT after invoking DBMS_JOB?
is job_queue_processes parameter non-zero?

You need to help us by following the Posting Guidelines as stated below.
http://www.orafaq.com/forum/t/88153/0/
Go to the URL above click the link "Posting Guidelines"
Go to the section labeled "Practice" & do as directed.

[Updated on: Tue, 08 December 2009 11:52]

Report message to a moderator

Re: execute a procedure automatically [message #434403 is a reply to message #434322] Wed, 09 December 2009 03:02 Go to previous messageGo to next message
sirfkashif
Messages: 70
Registered: September 2007
Location: Rawalpindi
Member
Quote:
i want the procedure to run automatically for every 5 minutes


did you mean to run this procedure after every 5 minutes interval?

if yes then try the below

begin
dbms_scheduler.create_job(
      job_name => 'send_mail'
     ,job_type => 'STORED_PROCEDURE'
     ,job_action => 'procedure_name'
     ,start_date => SYSTIMESTAMP
     ,repeat_interval => 'FREQ=DAILY;BYMINUTE=5'
     ,enabled => TRUE
     ,comments => 'Demo for job schedule');
end;


Hope it helps.

Regards,
Kashif
Re: execute a procedure automatically [message #434459 is a reply to message #434403] Wed, 09 December 2009 05:56 Go to previous messageGo to next message
ramoradba
Messages: 2454
Registered: January 2009
Location: AndhraPradesh,Hyderabad,I...
Senior Member
Please check the version and read this

I go with blakswan`s suggetion.

DBMS_JOB in 9i


sriram Smile

[Updated on: Wed, 09 December 2009 06:00]

Report message to a moderator

Re: execute a procedure automatically [message #434466 is a reply to message #434459] Wed, 09 December 2009 06:02 Go to previous messageGo to next message
Michel Cadot
Messages: 63804
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
Quote:
Please check the version

As stated in title version is 9i.
Please check the whole topic including title.

Regards
Michel
Re: execute a procedure automatically [message #434468 is a reply to message #434466] Wed, 09 December 2009 06:03 Go to previous messageGo to next message
ramoradba
Messages: 2454
Registered: January 2009
Location: AndhraPradesh,Hyderabad,I...
Senior Member
i know that ,And i did n`t say "what is your version?" please see my post again.i pointed this
Quote:
dbms_scheduler.create_job(


sriram Smile

[Updated on: Wed, 09 December 2009 06:05]

Report message to a moderator

Re: execute a procedure automatically [message #434470 is a reply to message #434322] Wed, 09 December 2009 06:05 Go to previous message
Michel Cadot
Messages: 63804
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
Have a look at Wiki pages DBMS_JOB and DBMS JOB complex scheduling.

Regards
Michel
Previous Topic: Wrapped procedure help please
Next Topic: I got a problem while writing a simple procedure
Goto Forum:
  


Current Time: Mon Sep 26 09:25:20 CDT 2016

Total time taken to generate the page: 0.10618 seconds