Home » Other » Client Tools » Table name in trc files? (Trace, 11, Windows 2003)
Table name in trc files? [message #321335] Mon, 19 May 2008 22:46 Go to next message
natelpeterson
Messages: 6
Registered: May 2008
Location: San Fran
Junior Member
I am trying to figure out how to see the actual query i wrote in a trace file...i did the following:

alter system set sql_trace=true;
(system altered)

i ran the following in sqlDeveloper:
select * from SimpleTable;

Should I be able to see this query in a trace file somewhere? (or how else do i identify a query, especially one from a session created through OLEDB?)

Thanks,
Nathan
Re: Table name in trc files? [message #321336 is a reply to message #321335] Mon, 19 May 2008 22:51 Go to previous messageGo to next message
BlackSwan
Messages: 26766
Registered: January 2009
Location: SoCal
Senior Member
>Should I be able to see this query in a trace file somewhere?
Yes, eventually & if you can find the correct trace file in the udump directory & process it with TKPROF.

alternatively
SQL> SET AUTOTRACE TRACE EXPLAIN STAT
SQL> select * from SimpleTable;
Re: Table name in trc files? [message #321342 is a reply to message #321336] Tue, 20 May 2008 00:06 Go to previous messageGo to next message
natelpeterson
Messages: 6
Registered: May 2008
Location: San Fran
Junior Member
Thanks for the info.
So if I do a system-wide trace (perhaps with 10046) and run an Analysis Services query against Oracle, there should exist a file in the dump dir that can only be read (the table name) with tkprof?
Re: Table name in trc files? [message #321634 is a reply to message #321342] Tue, 20 May 2008 22:23 Go to previous messageGo to next message
Dipali Vithalani
Messages: 278
Registered: March 2007
Location: India
Senior Member
Yes, you can see.. And there are 3 kind of dump directories and you can use trace files of User dump directory with tkproof for what you are looking for.

Regards,
Dipali
Re: Table name in trc files? [message #321668 is a reply to message #321342] Wed, 21 May 2008 00:27 Go to previous messageGo to next message
Michel Cadot
Messages: 68625
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
Trace file is text one and can be read with any editor.
Tkprof just analyzes it to display the result in another way.

Regards
Michel
Re: Table name in trc files? [message #321674 is a reply to message #321668] Wed, 21 May 2008 00:37 Go to previous message
natelpeterson
Messages: 6
Registered: May 2008
Location: San Fran
Junior Member
Thanks everyone. It turns out my problem was i was trying to use "search" in Windows explorer to find "SimpleTable" text within a file in the dump directory, and it couldn't find it...but when i looked through the files manually, i could find the text! Messed up, huh? Anyway I found what i was looking for, thanks everyone.
Previous Topic: SQL developer detecting wrong TnsName file
Next Topic: edit command in TOAD
Goto Forum:
  


Current Time: Fri Mar 29 09:17:16 CDT 2024