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: Job submission: interval error

Re: Job submission: interval error

From: Thomas Kyte <tkyte_at_us.oracle.com>
Date: 6 Jul 2001 07:04:47 -0700
Message-ID: <9i4ghv01ctc@drn.newsguy.com>

In article <994409066.309830_at_proxy.storm.co.za>, "Lee says...
>
>Sorry about the typos - I meant
>
>DECLARE
> JobNumber NUMBER;
>BEGIN
> DBMS_JOB.SUBMIT(:JobNumber,
> 'TX.GenerateWeeklyData;',
> SysDate,
> 'NEXT_DAY(TRUNC(SysDate),'SUNDAY')+0.5');
>END;
>

double up the quotes in the interval:

    'NEXT_DAY(TRUNC(SysDate),''SUNDAY'')+0.5');

>
>"Lee Staples" <lee_at_cybicom.co.za> wrote in message
>news:994406616.785184_at_proxy.storm.co.za...
>> Oracle 8.0.4
>>
>> I am attempting to submit a job using the following:
>>
>> DECLARE
>> JobNumber NUMBER;
>> BEGIN
>> DBMS_JOB.SUBMIT(:JobNumber,
>> 'TX.GenerateWeeklyData;',
>> SysDate,
>> 'NEXT_DAY(TRUNC(SysDate,'SUNDAY')+0.5';
>> END;
>>
>> as I want the job to run every Sunday at noon. But I keep getting a
 PL/SQL
>> compiler error complaining about 'SUNDAY'. This happens regardless of the
>> day I use. I can't get it to accept the NEXT_DAY function at all for the
>> interval.
>>
>> Any ideas?
>>
>> Thanks,
>> Lee.
>>
>>
>
>

--
Thomas Kyte (tkyte@us.oracle.com)             http://asktom.oracle.com/ 
Expert one on one Oracle, programming techniques and solutions for Oracle.
http://www.amazon.com/exec/obidos/ASIN/1861004826/  
Opinions are mine and do not necessarily reflect those of Oracle Corp 
Received on Fri Jul 06 2001 - 09:04:47 CDT

Original text of this message

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