The below script gets Oracle Home and Oracle SID from PL/SQL
Thanks
DECLARE
LC$ORACLE_HOME VARCHAR2 (2000);
LC$ORACLE_SID VARCHAR2 (256);
BEGIN
DBMS_SYSTEM.GET_ENV ('ORACLE_HOME', LC$ORACLE_HOME);
DBMS_SYSTEM.GET_ENV ('ORACLE_SID', LC$ORACLE_SID);
-- Oracle Home
DBMS_OUTPUT.PUT_LINE ('ORACLE_HOME = ' || LC$ORACLE_HOME);
-- Oracle SID
DBMS_OUTPUT.PUT_LINE ('ORACLE_HOME = ' || LC$ORACLE_SID);
END;
Thanks
No comments:
Post a Comment