patternMinor
Query to get ORACLE_HOME path in Oracle 11G
Viewed 0 times
path11goracle_homequerygetoracle
Problem
Can anyone help me out with an PL/SQL query to get the ORACLE_HOME path in Oracle 11G?
I require it to be fetched from the Oracle DB only & not via the Operating system's environment variables.
PS: I'm a DB newbie.
I require it to be fetched from the Oracle DB only & not via the Operating system's environment variables.
PS: I'm a DB newbie.
Solution
There is sys_context function
that works for Oracle 12c
select SYS_CONTEXT ('USERENV','ORACLE_HOME') from dual;
This does not work for lower versions of Oracle.
For 11g and lower versions, I don't know a simple method.
PS: I read @Balasz' answer and now I know a simple answer for version 11g.
that works for Oracle 12c
select SYS_CONTEXT ('USERENV','ORACLE_HOME') from dual;
This does not work for lower versions of Oracle.
For 11g and lower versions, I don't know a simple method.
PS: I read @Balasz' answer and now I know a simple answer for version 11g.
Context
StackExchange Database Administrators Q#97390, answer score: 6
Revisions (0)
No revisions yet.