select * from ( select a.sid session_id, a.SQL_ID, a.status, a.CPU_TIME/1000000 cpu_sec, a.BUFFER_GETS, a.DISK_READS, b.SQL_TEXT from v$sql_monitor a, v$sql b where a.SQL_ID = b.SQL_ID order by a.CPU_TIME desc)
It is a way to figure out where is this statement coming from? We have many procedures, is this can come from a query outside of oracle?It is easy to figure out, where these statements are coming from:
I see about 75 sessions showing this audit select statement with DONE status.Obviously, you have an active session which execute some sql queries. If they are finished, the status will be "DONE".
Is this ok? why so many sessions?
This is quite a well known badly performing query from, I think, OEM
SELECT TO_CHAR(current_timestamp AT TIME ZONE 'GMT', 'YYYY-MM-DD HH24:MI:SS TZD') AS curr_timestamp, COUNT(username) AS failed_count FROM sys.dba_audit_session WHERE returncode != 0 AND TO_CHAR(timestamp, 'YYYY-MM-DD HH24:MI:SS') >= TO_CHAR(current_timestamp - TO_DSINTERVAL('0 0:30:00'), 'YYYY-MM-DD HH24:MI:SS') what this text mean?