Monday, September 24, 2018

dba audit loginout

select
 USERNAME,to_char(timestamp, 'DD MON YYYY hh24:mi') logon_time,
 to_char(logoff_time,'DD MON YYYY hh24:mi') logoff,
 action_name
 from dba_audit_session
 order by logon_time,username,timestamp,logoff_time;



spool audit_user.txt
col ACTION_NAME for a12
col USERNAME for a15
select
 USERNAME,to_char(timestamp, 'DD MON YYYY hh24:mi') logon_time,
to_char(logoff_time,'DD MON YYYY hh24:mi') logoff,
action_name
from dba_audit_session
WHERE to_char(timestamp, 'DD MON YYYY hh24:mi') >='27 MAR 2017 17:21'
order by logon_time,username,timestamp,logoff_time;
spool off;
/


 

No comments:

Post a Comment

[ERROR]: The value of s_patch_service_name is not set correctly in atleast one of the context files.

[ERROR]: The value of s_patch_service_name is not set correctly in atleast one of the context files. I got the issue below wh...