Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: any way to know how old a transaction is
"rpr" <r_p_renu_at_yahoo.com> wrote in message
news:4db90929.0311101730.77b31371_at_posting.google.com...
> Hi,
> Is there a way for me to know how old an uncommitted transaction is.
> Meaning since how long it is there and uncommitted. Thank you
Yes. Have a look in v$transaction (you'll probably need to join it up with v$session to get the name of the user and so on). There's a column there called 'start_time' which will give you what you want to know.
Be warned: for reasons best known to Oracle, the start_time column is actually a VARCHAR2 column, and not a DATE one. So if you are going to do clock arithmetic ('show me all transactions which started more than 50 minutes ago', for example, you'll find it rather trickier than you would had it been a date field.
Regards
HJR
Received on Mon Nov 10 2003 - 22:59:06 CST