col "Am I Oracle DBA ?" format a15
select USERENV('ISDBA') "Am I Oracle DBA ?" from dual ;
col "Am I Oracle DBA ?" format a15
select USERENV('ISDBA') "Am I Oracle DBA ?" from dual ;
COLUMN curruser FORMAT A8 HEADING "Current|User"
COLUMN currschema FORMAT A8 HEADING "Current|Schema"
col "Am I Oracle DBA ?" format a15
select SYS_CONTEXT('USERENV', 'ISDBA') "Am I Oracle DBA ?" ,SYS_CONTEXT('USERENV', 'CURRENT_USER', 8) curruser,SYS_CONTEXT('USERENV', 'CURRENT_SCHEMA', 8) currschema from dual
col "Whereami -----" for a80
select 'Db Name : ' ||sys_context('USERENV', 'DB_NAME') ||chr(10) ||
'Instance Name : ' ||sys_context('USERENV', 'INSTANCE_NAME') ||chr(10) ||
'Container Name: ' ||sys_context('USERENV', 'CON_NAME') ||chr(10) ||
'Container Id : ' ||sys_context('USERENV', 'CON_ID') ||chr(10) ||
'User Name : ' ||sys_context('USERENV', 'SESSION_USER') ||chr(10) ||
'Host Name : ' ||sys_context('USERENV', 'SERVER_HOST') "Whereami -"
from dual;
No comments:
Post a Comment