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

Home -> Community -> Usenet -> c.d.o.server -> Re: ideas?

Re: ideas?

From: Daniel Morgan <damorgan_at_exesolutions.com>
Date: Thu, 30 May 2002 22:14:09 -0700
Message-ID: <3CF706A1.BFE16353@exesolutions.com>


Galen Boyer wrote:

> On Thu, 30 May 2002, bgt0990_at_trim.net wrote:
>
> > I'm a little rusty with my scripting, can someone give me a push in
> > the right direction. (I need to implement on an ver 8.1.5 NT4.0
> > server). What I need to do is fairly simple IE remove log files after
> > I know they have been applied in this manual standby server.
> > Basically;
> >
> > select sequence# from v$log_history
> >
> > delete any 'arcSEQ.001' from the d:\oracle\archcopy directory
> >
> > where SEQ is the sequence found from the v$log_history query.
> >
> > We don't have any programming tools to work with here other than
> > DOS/SHELL and SQL/PL/SQL
>
> Download the cygwin toolset, www.cygwin.com and write a "#!/bin/sh" file.
>
> #!/bin/sh
> echo "#!/bin/ksh" > runthis.sh
> sqlplus user/pass_at_instance <<EOF >> runthis.sh
> select 'rm d:\oracle\archcopy\arc' || sequence# || 'SEQ.001' from v$log_history;
> EOF
>
> chmod 777 runthis.sh
> runthis.sh
>
> --
> Galen deForest Boyer
> Sweet dreams and flying machines in pieces on the ground.

How do you run a shell script under MS Windows?

Daniel Morgan Received on Fri May 31 2002 - 00:14:09 CDT

Original text of this message

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