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: monitor sql sentences

Re: monitor sql sentences

From: dombrooks <dombrooks_at_hotmail.com>
Date: 11 Jan 2007 12:54:39 -0800
Message-ID: <1168547133.707331.317670@k58g2000hse.googlegroups.com>

Shinya Koizumi wrote:
> How to monitor the executed sql sentence from GUI?
>
> Is it possible?
>
> SK

Hi,

This is possible by using extended trace provided you can identify the session(s).
 ALTER SESSION SET sql_trace = TRUE
or
 ALTER SESSION SET events '10046 trace name context forever, level 1/4/8/12' which depending on that last number could show you extra information like bind variables or waits or both.

Depending on the number of sessions in your database, you could set the relevant tracing across the whole database or you could use an after logon trigger to isolate only session connecting as a certain username or a certain application or possibly even using a certain IP I suppose (using USERENV SYS_CONTEXT). Other mechanisms to set this include oradebug, dbms_monitor and dbms_system.

Cheers,
Dominic Received on Thu Jan 11 2007 - 14:54:39 CST

Original text of this message

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