Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> Re: sqlplus within the unix shell
In article <850f5b$m52$1_at_bob.news.rcn.net>,
"Eugene Firyago" <efiryago_at_bisys.com> wrote:
> 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.
>
>
Yes, if you want to do something like this...
# we want to get the log sequence number that Oracle thinks is current
SeqNo=$( echo "set heading off feedback off verify off
select sequence# from v\$log where status = 'CURRENT';"| \ sqlplus -s / )
You can do quite a lot with the commands you push into sqlplus but it can look very nasty.
Hth... Steve Mundie
Sent via Deja.com http://www.deja.com/
Before you buy.
Received on Thu Jan 06 2000 - 05:56:13 CST
![]() |
![]() |