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: Trace SQL statements executed

Re: Trace SQL statements executed

From: Sybrand Bakker <postmaster_at_sybrandb.demon.nl>
Date: Wed, 14 Jul 1999 21:55:41 +0200
Message-ID: <931982111.5086.0.pluto.d4ee154e@news.demon.nl>


From a post by Tim Lange, of yesterday
If the session already exists, go to v$session and get the sid and the serial# of the session you are interested in. .
Then, using sqlplus, as "sys" unless you granted additional authority,

       execute dbms_system.set_sql_trace_in_session(sid, ser, TRUE);

when finished

       execute dbms_system.set_sql_trace_in_session(sid, ser, FALSE);

Hth,

Sybrand Bakker, Oracle DBA

Keith Shum <kshum_at_iLux.com> wrote in message news:7mikme$o2u$1_at_nnrp1.deja.com...
> Hi, there,
>
> Currently I have a problem with a client product which will import
> tons of data into Oracle8 database. However, during importing in the
> middle, it stopped. Does anyone know how to turn on the trace mode that
> will log down every SQL statement executed by the client from the
> database server side?
>
> Since I have heard about the "CPU Spin"-kind of SQL statements that
> will execute forever and never return anything. I would like to do a
> debug to see which statement is having problem. However, I cannot
> execute them one by one by hand.
>
> Thank you!
>
>
>
> --
> **********
> Keith Shum @>~>~
> kshum_at_iLux.com
>
>
> Sent via Deja.com http://www.deja.com/
> Share what you know. Learn what you don't.
Received on Wed Jul 14 1999 - 14:55:41 CDT

Original text of this message

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