All posts relating to Oracle database administration.

Moderator: Tim...



Postby Guest » Mon Nov 01, 2004 6:09 pm

i have done this that if we set SQL_TRACE to TRUE all users's statements are traced at user_dump_dest...i want to know that if we want to on SQL_TRACE for a singlke session then ths use must set it on byt himself...so how can we force a user to do this...should we set it on in our application??? and if we do like this then how we will set it off for that session because it is hard coded in application..i dont understand to set it true for a session
second thing is if we dont set ir true stilli can see files at USER_DUMP_DEST...what are theese for??

Site Admin
Posts: 18437
Joined: Mon Nov 01, 2004 5:56 pm
Location: England, UK


Postby Tim... » Mon Nov 01, 2004 6:09 pm


You can set it from your application using the "alter session" statement or the dbms_session package. See:

https://oracle-base.com/articles/8i/ ... In_Session

Alternatively, you can set it from a privileged session using the dbms_system package:

https://oracle-base.com/articles/8i/ ... In_Session

SQL trace can add quite an overhead so this should only be switched on for debuging purposes.

Alternatively, create a system trigger that switches SQL trace on when a session logs in.


Oracle ACE Director
Oracle ACE of the Year 2006 - Oracle Magazine Editors Choice Awards
OakTable Member
OCP DBA 7.3, 8, 8i, 9i, 10g, 11g
OCP Advanced PL/SQL Developer
Oracle Database: SQL Certified Expert
My website: https://oracle-base.com
My blog: https://oracle-base.com/blog

Return to “Oracle Database Administration”

Who is online

Users browsing this forum: No registered users and 2 guests