DBMS_SCHEDULER.create_job


BEGIN
 DBMS_SCHEDULER.create_job (
 job_name => 'MIS_CLIENT_REPORT',
 job_type => 'PLSQL_BLOCK',
 job_action => 'BEGIN OC_YKB.MIS_CLIENT_REPORT.RUN_REPORT; END;',
 start_date => to_date('18.11.2013 04:00:00','dd/mm/yyyy hh24:mi:ss'),
 repeat_interval => 'FREQ=MONTHLY; BYMONTHDAY=1;',
 end_date => NULL,
 enabled => TRUE,
comments => 'Reporting..');
END;

/*Enable job*/
BEGIN
DBMS_SCHEDULER.ENABLE ('MIS_CLIENT_REPORT');
END;

/*disable job*/
BEGIN
DBMS_SCHEDULER.disable ('MIS_CLIENT_REPORT');
END;

/*drop job*/
begin
dbms_scheduler.drop_job(job_name => 'MIS_CLIENT_REPORT');
end;

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: