How can you enable a trace for a session?

Answer Posted / guest

Enable trace at session level

( A )to start trace:

ALTER SESSION SET sql_trace = TRUE;

- or -
EXECUTE dbms_session.set_sql_trace (TRUE);

- or -


EXECUTE dbms_support.start_trace;


(B) to stop trace:

ALTER SESSION SET sql_trace = FALSE;

- or -

EXECUTE dbms_session.set_sql_trace (FALSE);

- or -

EXECUTE dbms_support.stop_trace;


Regards
Abhinav Phadnis

Is This Answer Correct ?    5 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

how can you generate profile of pl/sql applications to identify performance bottlenecks?

596


What purpose does the model database server? : sql server DBA

624


Define the SGA and: How you would configure SGA for a mid-sized OLTP environment? What is involved in tuning the SGA?

3309


What happens on checkpoint? : sql server DBA

564


How to bind a cobol module to a given job? I am not able to understand this concept.Can anyone help me out as how to carry out this task?

1653






what is the use of ocr?

595


when does an alert gets signaled?

578


Which autogrowth database setting is good? : sql server DBA

574


Draft one mock email requesting your non-technical management grant you downtime to (provide justification where applicable) complete the following tasks: (1) Generate statistics on a large table; (2) Generate an RDA – if you don't know what an RDA is please say so. (3) Rename datafiles.

1688


What is the default port no on which sql server listens? : sql server DBA

556


In which dictionary table or view would you look to determine at which time a snapshot or MVIEW last successfully refreshed?

2226


Why would you call update statistics? : sql server DBA

575


what is a crs resource?

595


Assuming today is Monday, how would you use the DBMS_JOB package to schedule the execution of a given procedure owned by SCOTT to start Wednesday at 9AM and to run subsequently every other day at 2AM.

1697


how does an oracle clusterware manage crs resources?

569