Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

dbms_system.get_env

57043Jul 3 2008 — edited Jul 3 2008
Hi,

I am using Oracle 10g running on unix and try to get unix env value in pl/sql block. For this I want to use dbms_system. In system currently there are two users in Oracle DB mainly. ops$o and v. ops$o is having unix account while v is not having unix account. My questions regarding this,

1. as user ops$a I am getting only selected values not all for e.g.
SQL> show user
USER is "OPS$O

SQL> exec sys.dbms_system.get_env('PWD',:d);

PL/SQL procedure successfully completed.


D
--------------------------------------------------------------------------------
/apps/oracle

SQL>

SQL> !env |grep -i V
VROOT=/apps/webservers/I6WDD0
VF=/apps/webservers/I6WDD0

SQL> exec sys.dbms_system.get_env('VROOT',:d);

PL/SQL procedure successfully completed.


D
--------------------------------------------------------------------------------


SQL>

Why it is not showing this variable value ?

2. Suppose I get value in ops$o how user "v" can access this value ?

3. Is dbms_system package supported by oracle 10g ? I could not get reference in PL/SQL packages Reference manual in 10g

4. Other than dbms_system, there may be various ways to get unix variable values, what should be simple and efficient way to achive this ?

pl guide me.

thanks & regards
parag
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jul 31 2008
Added on Jul 3 2008
4 comments
1,461 views