Re: Oracle Trace

From: Charles Hooper <>
Date: Sun, 8 Feb 2009 06:12:51 -0800 (PST)
Message-ID: <>

On Feb 7, 12:41 pm, Mtek <> wrote:
> Ok, dumb question.
> I am running Oracle trace.  I want to suppress the query's output and
> just see the explain plan.......
> Can't seem to find it in the manual or on any other sites......
> If I would say select * from <table>, I do not want to see all the
> data, just the explain plan.....

Paraphrased from "Mastering Oracle SQL and SQL*Plus": SET AUTOTRACE TRACEONLY EXPLAIN displays explain plans without executing the query.
SET AUTOTRACE TRACEONLY STATISTICS suppresses the output from the query and displays the statistics from the execution. SET AUTOTRACE ON EXPLAIN shows the explain plan after the query executes.

You will want to use the second of the above to see the statistics without outputting the rows, or use the first of the above to output the expected execution plan without executing the query. To output the expected execution plan and the runtime statistics without the intermediate output from the SQL statement, you should be able to use the following:
IT Manager/Oracle DBA
K&M Machine-Fabricating, Inc. Received on Sun Feb 08 2009 - 08:12:51 CST

Original text of this message