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: Getting Unix environment variable from SQL or PL/SQL

Re: Getting Unix environment variable from SQL or PL/SQL

From: <mgogala_at_yahoo.com>
Date: Wed, 03 Feb 1999 02:17:38 GMT
Message-ID: <798bjq$b7n$1@nnrp1.dejanews.com>


In article <36B606B3.88E75328_at_bio.ri.ccf.org>,   Mohammad Farid <mfarid_at_bio.ri.ccf.org> wrote:
>
> You can user 'host' or '!' at the sql prompt.
> e.g.
> SQL> host env
> or
> SQL> host echo $ORACLE_SID
>
> Maverick wrote:
>
> > Hi
> >
> > Does anyone know how to get Unix environment variables from SQL
> > or PL/SQL.
> >
> > Thank you in advance.
> >
> > Please send all comments to: mav_at_ghg.net
>
>

In Oracle8, you could use external procedure which would essentially invoke getenv, but that would only show you the environment variables for the oracle server process which is executing your PL/SQL. Unless the environment variable you are looking for is one of the classic ones (HOSTNAME,MAIL,HOME) it want do you much good.

Mladen Gogala

-----------== Posted via Deja News, The Discussion Network ==---------- http://www.dejanews.com/ Search, Read, Discuss, or Start Your Own Received on Tue Feb 02 1999 - 20:17:38 CST

Original text of this message

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