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

Home -> Community -> Mailing Lists -> Oracle-L -> RE: Urgent! How to verify what a database connection is doing?

RE: Urgent! How to verify what a database connection is doing?

From: Reardon, Bruce (CALBBAY) <Bruce.Reardon_at_comalco.riotinto.com.au>
Date: Mon, 05 Mar 2001 14:15:34 -0800
Message-ID: <F001.002C42EE.20010305141124@fatcity.com>

Larry,

Try the following.

Regards,
Bruce

select username, q.*

    from

       v$session s , v$sql q
    where

              q.address = s . sql_address
       and q.hash_value = s.SQL_HASH_VALUE
       and s.username = '&userr'

    ;

select /*+RULE*/ a.address,

           a.buffer_gets, 
           a.executions, 
           b.piece, 
           b.sql_text 

from v$sqlarea a, v$sqltext b , v$session s
where a.ADDRESS = b.ADDRESS 
and   a.HASH_VALUE = b.HASH_VALUE 
and   a.hash_value = s.sql_hash_value
and   s.sid=&sidd

order by 1,4;

select /*+RULE*/ a.address,

           a.buffer_gets, 
           a.executions, 
           buffer_gets/executions, 
           b.piece, 
           b.sql_text 

from v$sqlarea a, v$sqltext b
where executions > 0
and a.ADDRESS = b.ADDRESS
and a.HASH_VALUE = b.HASH_VALUE
order by 1,5;

-----Original Message-----
Sent: Tuesday, 6 March 2001 8:58
To: Multiple recipients of list ORACLE-L

Hi all,

Is there any way to know what sql statament a connection is currently running.
My database 8.1.6.0.0 is suddenly causing our operation system (sun solaris 2.7) to
plunge into Swap. There are no other applications running on this machine.

I would like to know if I can look at what a connection is doing, do you have any
suggestions?

tia

Larry
--

Please see the official ORACLE-L FAQ: http://www.orafaq.com
--

Author: Reardon, Bruce (CALBBAY)
  INET: Bruce.Reardon_at_comalco.riotinto.com.au

Fat City Network Services    -- (858) 538-5051  FAX: (858) 538-5051
San Diego, California        -- Public Internet access / Mailing Lists
--------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message to: ListGuru_at_fatcity.com (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). Received on Mon Mar 05 2001 - 16:15:34 CST

Original text of this message

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