Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.tools -> Re: Creating Job (or scheduling of SQL scripts)

Re: Creating Job (or scheduling of SQL scripts)

From: <marcpark_at_my-deja.com>
Date: 2000/05/03
Message-ID: <8epcdt$13u$1@nnrp1.deja.com>#1/1

Use The DBMS_Jobs package.

example
variable x number;
execute dbms_job.submit(:x, -

                'My_Package.My_Procedure;', -
                sysdate, -
                'sysdate + 1/48' -
                );

execute dbms_job.run(:x);

This should work

Marc Parkinson
Oracle Developer

In article <8enafc$fu6$1_at_nntp9.atl.mindspring.net>,   "lorax" <dpeel_at_mindspring.com> wrote:
> Hey all,
>
> I'm trying to schedule a SQL script to run at a regular interval (1/2
 hour).
> I am using the OEM (Oracle 8.1.5, OEM version 2.04) to create a job to
> perform this task. I can create a job, but, no matter what I use for
 the
> SQL script, the job shows completed without errors, but, the script
 does not
> run. (I can type complete nonsense in for the script and still show
 job
> complete without errors) The documentation suggests adding a line
 such as
> "whenever sql error" (I don't have the exact syntax in front of me).
 I can
> add that line, but, to no avail. If I take a copy of the SQL script
 and run
> it under a SQL worksheet, it works.
>
> Is there a problem with calling stored procedures from this job?
>
> I have never tried to set up a job this way. Any suggestions about
 what I
> might be doing wrong? Another way of doing?
>
> Thanks much,
>
> Doug
>
> dpeel_at_mindspring.com
>
>

Sent via Deja.com http://www.deja.com/
Before you buy. Received on Wed May 03 2000 - 00:00:00 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US