Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: v$session

Re: v$session

From: Kristiaan J. Kolk <akolk_at_gelrevision.nl>
Date: 1999/01/13
Message-ID: <77hrvq$t5u$1@thor.wirehub.nl>#1/1

Well,
it could be possible that you executed the statement twice !

Anjo.
Marco Koch wrote in message <368b5898.812858_at_news.freiburg.toplink.de>...
>Hello everybody,
>
>I would like to get the source for the last SQL statement.
>I tried the following:
> SELECT
> st.piece,
> st.sql_text
> FROM
> v$session sess,
> v$sqltext st
> WHERE
> sess.prev_sql_addr=st.address
> AND sess.prev_hash_value = st.hash_value --What is the difference
>between sql_addr and hash_value???
> AND sess.Username = user
> ORDER BY
> st.piece;
>
>But this will only return the current SQL statement. So I
>tried the following statement:
> SELECT
> sess.sql_address,
> sess.sql_hash_value,
> sess.prev_sql_addr,
> sess.prev_hash_value
> FROM
> v$session sess
> WHERE
> sess.Username = user;
>
>And I get the following result set:
>SQL_ADDR SQL_HASH_VALUE PREV_SQL PREV_HASH_VALUE
>-------- -------------- -------- ---------------
>023569DC -1.64E+09 023569DC -1.64E+09
>
>It seems to me that the attributes SQL_ADDRESS and PREV_SQL_ADDR
>have the same values. Did I miss something here?? Or does anybody what
>is
>wrong here??
>
>Thanks in advance,
> -Marco Koch
>
>
> \\|//
> (o o)
> __________________________ooO-(_)-Ooo___________________________
> /\ \
> \_| Marco Koch Informatik |
> | Marco Koch Tel: +49-(0)761-73913 |
 

> | Guenterstalstr.16 Tel: +49-(0)761-2020283 priv. |
> | 79100 Freiburg Tel: +49-(0)761-203-8126 university |
> | Germany |
> | email: mkoch_at_privat.toplink.de |
> | email: koch_at_informatik.uni-freiburg.de (university) |
> | <http://www.informatik.uni-freiburg.de/~koch/> |
> | ______________________.oooO___________________________________|
> \_/_____________________( )___Oooo.__________________________/
> \ ( ( )
> \_) ) /
> (_/
>
>
>
>
Received on Wed Jan 13 1999 - 00:00:00 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US