Oracle: What is the ORACLE_SID and DB_NAME name ?
2011-08-11 15:35 Tracy. 阅读(289) 评论(0) 编辑 收藏 举报Query the views v$database and v$thread.
V$DATABASE gives DB_NAME
V$THREAD gives ORACLE_SID
If ORACLE_SID = DB_SID and db_name = DBNAME:
To find the current value of ORACLE_SID:
SVRMGR> select instance from v$thread;
INSTANCE
----------------
DB_SID
To find the current value of DB_NAME:
SVRMGR> select name from v$database;
NAME
---------
DBNAME
本文来自博客园,作者:Tracy.,转载请注明原文链接:https://www.cnblogs.com/tracy/archive/2011/08/11/2135082.html