Home » RDBMS Server » Server Administration » Finding the sql statements executed in a session
Finding the sql statements executed in a session [message #370769] Thu, 03 February 2000 08:57 Go to next message
KARTHIKR
Messages: 3
Registered: February 2000
Junior Member
Is it possible to find out all the sql statements that have been executed in a session from another session

Thanx in Advance
Re: Finding the sql statements executed in a session [message #370771 is a reply to message #370769] Thu, 03 February 2000 19:16 Go to previous messageGo to next message
MikeG
Messages: 14
Registered: August 1999
Junior Member
as system...select * from v$sql_area
Re: Finding the sql statements executed in a session [message #370783 is a reply to message #370771] Mon, 07 February 2000 13:24 Go to previous messageGo to next message
KARTHIKR
Messages: 3
Registered: February 2000
Junior Member
BUT THE V$SQLAREA IS NOT SPECIFIC TO THE SESSION,
IT CONTAIS ALL THE SQL STATEMENTS.....
HOW TO EXTRACT THE STATEMENTS TO PARTICULAR STATEMENTS
Re: Finding the sql statements executed in a session [message #370787 is a reply to message #370771] Tue, 08 February 2000 06:20 Go to previous message
Thierry Van der Auwera
Messages: 44
Registered: January 2000
Member
Hallo,

Yes this contains all the commandos for all the users,
but you can select it also for one userid.

Try following sql, you only have to set the username (in uppercase)
so alter 'THE_USER_NAME' to a the username you want.
Note: this is not session dependent, but user dependent.

SELECT *
FROM sys.v_$sqlarea
WHERE parsing_user_id = (SELECT DISTINCT user#
FROM sys.v_$session
WHERE username = 'THE_USER_NAME');

Hope this helps you.

Greetings,

Thierry.
Previous Topic: Transaction conducted in the last n min or m sec. in oracle
Next Topic: How to close LOGON_SCREEN pop up without any entry?
Goto Forum:
  


Current Time: Thu Mar 28 05:29:50 CDT 2024