Home » RDBMS Server » Server Administration » Last time of statement execution
Last time of statement execution [message #329912] Fri, 27 June 2008 01:11 Go to next message
srini_thiru
Messages: 133
Registered: May 2008
Senior Member


Hi to all,

I like to know the time of the last executed statement by a session.


For example,

user1 has logged on to the database by the time '25-jun-08 13:25:00'. Now the time is '26-jun-08 22:15:30'. whether can i get the information when he has executed the last statement.

Any dynamic views to view this..

thanks in advance,

Seenu
Re: Last time of statement execution [message #329915 is a reply to message #329912] Fri, 27 June 2008 01:15 Go to previous messageGo to next message
Michel Cadot
Messages: 64153
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
No way.

Regards
Michel
Re: Last time of statement execution [message #331845 is a reply to message #329915] Sat, 05 July 2008 23:36 Go to previous messageGo to next message
ora110
Messages: 42
Registered: September 2007
Location: China
Member

you need not to do that .
Re: Last time of statement execution [message #331912 is a reply to message #329915] Sun, 06 July 2008 09:55 Go to previous messageGo to next message
srini_thiru
Messages: 133
Registered: May 2008
Senior Member


Hi,

I found the answer to my question.

One can Find when the particular user has executed the last statement by using the below query.


select sid,username,floor(last_call_et/60) "Activity in Minutes"
from v$session;

The column "Activity in Minutes" will show time of the user's activity in the database in minutes.


Thanks & Regards,
Seenu
Re: Last time of statement execution [message #331920 is a reply to message #331912] Sun, 06 July 2008 10:41 Go to previous message
Michel Cadot
Messages: 64153
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
This is not true.
If the session is active this shows how much time the last call lasts
If the session is not active this shows how much idle time since the last call.
A call is NOT a statement, it is a part of it.

Regards
Michel
Previous Topic: to take a job offline
Next Topic: maximum number of processes exceeded
Goto Forum:
  


Current Time: Sun Dec 11 08:32:13 CST 2016

Total time taken to generate the page: 0.08244 seconds