 |
|
Oracle Replication Tips by Burleson |
Creating a Oracle Job
DBMS_JOB.BROKEN(job => 1, broken =>
TRUE); END;
/
Job 1 is now broken and will not execute. To restart Job 1, you
must reset BROKEN to false and reset the Next Date. When a job is
broken, the Next Date is set to 01 Jan 4000.
BEGIN
DBMS_JOB.CHANGE(job => 1,
next_date => SYSDATE,
interval =>'trunc(SYSDATE+1/24,'HH')',
what => NULL);
END;
/
BEGIN
DBMS_JOB.BROKEN(job => 1,
broken => FALSE);
END;
/
The first step uses dbms_job.change
to reset the next_date
and interval
parameters. next_date
will be the next time the job will actually run. interval
will determine when the job will be scheduled for its next execution
after next_date
arrives and the job executes. The second step uses
dbms_job.broken
to set the broken flag of the job to FALSE, thus allowing it to be
scheduled once again.
This is an
excerpt from Oracle Replication By Rampant TechPress (only $19.95).
You can click here to order a copy and get instant access to the code
depot:
http://www.rampant-books.com/book_2003_2_replication.htm
Get a Personal Oracle
Replication Mentor
The author is now offering personal mentors for
Oracle DBAs where you can have an Oracle expert right at your
fingertips, anytime day or night. We work with hundreds of Oracle
databases every year, so we know exactly how to quickly assist you
with any Oracle replication question.
You can get me personally, or any Oracle Certified replication DBA
with more than 20 years of full-time IT experience.

|