Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> Re: Find all SQLs run from one session
Randi W wrote:
> Is it possible by querying system tables to find all sql-statements that
> have been run from one session?
No. If a SQL handle has been closed by the client, then Oracle no longer has a reference to who owns a SQL statement in the shared pool.
You can only determine (via V$ views) what current SQL handles (open cursors) are owned by a session.
> What tables/views should I look into to find this?
V$OPEN_CURSOR contains the SID (Oracle session id - see V$SESSION) of who owns the ADDRESS and HASH VALUE (aka "SQL Address") of a SQL statement in the shared pool (see V$SQLTEXT for actual SQL text).
-- BillyReceived on Mon Aug 22 2005 - 03:28:50 CDT
![]() |
![]() |