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: sqlplus within the unix shell

Re: sqlplus within the unix shell

From: Michel Cadot <micadot_at_netcourrier.com>
Date: Thu, 6 Jan 2000 09:33:52 +0100
Message-ID: <851k1p$ul2$1@news4.isdnet.net>


Here's a script from Kenneth C Stahl <BlueSax_at_Unforgettable.com> that works fine for that:

#!/bin/ksh
MyVar=$(sqlplus -s system/manager <<sqlEOF whenever sqlerror exit failure;
set feedback off;
set pages 0;
variable id number;
begin
select 1
into :id
from dual;
end;
.
/
print id
exit success;
sqlEOF)
print -u1 $MyVar;
exit 0;

--
Have a nice day
Michel

Eugene Firyago <efiryago_at_bisys.com> a écrit dans le message : 850f5b$m52$1_at_bob.news.rcn.net...
> Is it possible the unix shell to see/handle the result as sqlplus variables
> of a sqlplus script run from within a shell script?
>
> Thanks in advance,
> Eugene.
>
>
>
Received on Thu Jan 06 2000 - 02:33:52 CST

Original text of this message

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