This is what I use to see what sql they are running:

select  c.osuser unix_user,
        c.process,
        c.username ora_user,
        c.sid,
        c.program,
        c.terminal,
        a.sql_text
from    v$session c,
        v$sqlarea a,
        v$process p
where p.addr = c.paddr
  and c.process is not NULL
  and c.sql_address = a.address(+)
  and c.sql_hash_value = a.hash_value(+)
  and p.spid = &1
order by c.osuser, c.process
/






>From: ora ak <[EMAIL PROTECTED]>
>Reply-To: [EMAIL PROTECTED]
>To: Multiple recipients of list ORACLE-L <[EMAIL PROTECTED]>
>Subject: RE: Any way to see the currently  running SQL in one session.
>Date: Wed, 16 Oct 2002 08:04:09 -0800
>
>
>there is a x$ table which can give u this info I am not able to recall that 
>at the moment .
>oramagic
>  Paulo Gomes <[EMAIL PROTECTED]> wrote:u could use top sessions
>
>-----Original Message-----
>Sent: quarta-feira, 16 de Outubro de 2002 2:28
>To: Multiple recipients of list ORACLE-L
>
>
>Dear ALL,
>
>Is there any way to see the currently running SQL in one session? I
>used v$open_cursor, but there might be many SQL statements, I don't know
>which one is currently running. And more, if I execute a stored procedure,
>which SQL statements could be seen in v$open_cursor?
>
>Any clues would be much appreciated.
>
>TIA
>
>Chuan
>--
>Please see the official ORACLE-L FAQ: http://www.orafaq.com
>--
>Author: Paulo Gomes
>INET: [EMAIL PROTECTED]
>
>Fat City Network Services -- 858-538-5051 http://www.fatcity.com
>San Diego, California -- Mailing list and web hosting services
>---------------------------------------------------------------------
>To REMOVE yourself from this mailing list, send an E-Mail message
>to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
>the message BODY, include a line containing: UNSUB ORACLE-L
>(or the name of mailing list you want to be removed from). You may
>also send the HELP command for other information (like subscribing).
>
>
>---------------------------------
>Do you Yahoo!?
>Faith Hill - Exclusive Performances, Videos, & more
>faith.yahoo.com


_________________________________________________________________
Internet access plans that fit your lifestyle -- join MSN. 
http://resourcecenter.msn.com/access/plans/default.asp

-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.com
-- 
Author: Mike Killough
  INET: [EMAIL PROTECTED]

Fat City Network Services    -- 858-538-5051 http://www.fatcity.com
San Diego, California        -- Mailing list and web hosting services
---------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).

Reply via email to