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

Home -> Community -> Usenet -> c.d.o.misc -> Re: Batch File + SQLPlus commands

Re: Batch File + SQLPlus commands

From: Mark Day <mark.day_at_solortec.co.uk>
Date: Thu, 4 Mar 2004 07:52:02 +0000 (UTC)
Message-ID: <c26n72$p0l$1@sparta.btinternet.com>


Thanks very much Frank, thats just what I was looking for.

Mark Day.

"Frank van Bortel" <fvanbortel_at_netscape.net> wrote in message news:c22tl9$eqg$1_at_news4.tilbu1.nb.home.nl...
> Mark Day wrote:
>
> > Hi All,
> > Everyday I have to enter an sqlplus command from the sqlplus GUI and I
would
> > like to create a batch file that I could schedule to automate this. When
I
> > open the sqlplus GUI I always type 'EXECUTE
> > mms_pps_comm.New_Row_In_OrdersFromPPS;' then 'COMMIT;' finally exiting
from
> > the GUI.
> >
> > I have created a batch that contains the line below:
> > D:\oracle\ora80\BIN\PLUS80W.EXE system/MANAGER @PPS.sql
> >
> > My PPS.sql is:
> > BEGIN
> > EXECUTE mms_pps_comm.New_Row_In_OrdersFromPPS;
> > END;
> > /
> > COMMIT
> > /
> > EXIT
> >
> > But this doesn't appear to be working. Can anbody give me an example of
what
> > I'm missing in my .sql file?
> >
> > Many Thanks.
> > Mark Day.
> >
> >
> Drop the execute:
> begin
> mms_pps_comm.New_Row_In_OrdersFromPPS;
> end;
> commit;
>
> execute (or exec for short) is the sql*plus equivalent of
> a begin before, and an end; after the statement, or:
> exec mms_pps_comm.New_Row_In_OrdersFromPPS;
> is equal to:
> begin mms_pps_comm.New_Row_In_OrdersFromPPS; end;
> --
>
> Regards,
> Frank van Bortel
>
Received on Thu Mar 04 2004 - 01:52:02 CST

Original text of this message

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