sql_trace [message #37668] |
Tue, 19 February 2002 20:43 |
krishna
Messages: 141 Registered: October 1998
|
Senior Member |
|
|
When i set the sql_trace=true, very soon hundreds of trace files accumulate in the udump directory. I need to know how to identify which trace file i need to pass as the input file parameter in the tkprof statement. Identifying which is the correct file is driving me crazy. Can u help please?
|
|
|
Re: sql_trace [message #37680 is a reply to message #37668] |
Wed, 20 February 2002 07:45 |
andrew again
Messages: 2577 Registered: March 2000
|
Senior Member |
|
|
Generally if you are one of the only people doing tracing then finding the most recent file in the udump dir is all you need (in unix --> ls -ltr). The queries below will give you the filename and path. From asktom.oracle.com
On Unix:
select c.value || '/' || d.instance_name || '_ora_' || to_char(a.spid,'fm99999')
|| '.trc'
from v$process a, v$session b, v$parameter c, v$instance d
where a.addr = b.paddr
and b.audsid = userenv('sessionid')
and c.name = 'user_dump_dest';
on NT:
select c.value || 'ORA' || to_char(a.spid,'fm00000') || '.trc'
from v$process a, v$session b, v$parameter c
where a.addr = b.paddr
and b.audsid = userenv('sessionid')
and c.name = 'user_dump_dest';
|
|
|