Re: Referencing Unix vars with SqlPlus

From: Aaron Werman <awerman_at_gramercy.ios.com>
Date: 1996/07/26
Message-ID: <31F91DFA.6A3A_at_gramercy.ios.com>#1/1


Afshin Ghafoori wrote:
>
> djensen_at_nyx10.cs.du.edu (Dave Jensen) wrote:
>
> >Does anybody know of a way to reference Unix variables from within SqlPlus?
> >I'd like to do this without having to pass them as parameters to the script.
> >For example...
> >Sqlplus /
> > select '$unixvar' from dual;
 

> >I know that the above syntax does not work, but is it possible? HOW???
 

> >Dave Jensen
> >Jensen Consulting
> >djensen_at_ares.csd.net
 

> >><> Sheltie Fan and Oracle Database Consultant <><
>
> I assume you use Ksh:
>
> sqlplus ${USERNAME}/${PASSWORD} <<! > output.lst
>
> SELECT '${PWD}'
> FROM dual
> /
> !

How about:

	SQL> host select '$unixvar' from dual >/tmp/temp.sql
	SQL> _at_/tmp/temp
Received on Fri Jul 26 1996 - 00:00:00 CEST

Original text of this message