Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> Re: reading unix host variables within PL/SQL
You could spool the host commands to create a select statement into a sql file, then run the sql file.
This is untested. You will have to play with the "'s to get them right. Once it works you could then rewrite it to create a cursor.
set pagesize 0
spool /tmp/a.com
select "echo ""select \""$LOGNAME\"" from dual;"" > /tmp/a.sql"
spool off
host (". /tmp/a.com") ;
@/tmp/a.sql
host ("rm /tmp/a.com /tmp/a.sql") ;
rob joss (rob_joss_at_lilly.com) wrote:
: I have not been able to find a way of reading unix host variables from
: either SQLPLUS or within PL/SQL.
: Does anyone how to do this?
: Thanks
-- This posting represents the personal opinions of the author. It is not the official opinion or policy of the author's employer. Warranty expired when you opened this article and I will not be responsible for its contents or use.Received on Tue Jun 17 1997 - 00:00:00 CDT
![]() |
![]() |