Re: Inconsistent SQL tuning results
Date: Mon, 07 Feb 2011 10:59:44 -0700
Message-ID: <4D503310.6050408_at_optimaldba.com>
Without additional information, the only option available is "Guess".
Run extended sql trace (dbms_monitor.session_trace_enable, event 10046, etc), run the trace file(s) through tkprof and analyze the differences.
On 2/7/2011 10:49 AM, Michael Moore wrote:
> I've been trying to tune a SQL statement but I get very inconsistent
> results.
>
> I always start with:
> alter system flush shared_pool;
> alter system flush buffer_cache;
>
> Then I run the SQL, but the first time I run it, it can take as much
> as 7 minutes. On the 2nd, 3rd, and 4th runs, it takes
> 40 sec, 49 sec, 35 sec respectively.
>
> So my question is: What might account for the huge difference in run
> time between the first run and successive runs?
>
> Thanks,
> Mike
>
>
>
> No virus found in this incoming message.
> Checked by AVG - www.avg.com
> Version: 9.0.872 / Virus Database: 271.1.1/3428 - Release Date: 02/07/11 00:34:00
>
-- http://www.freelists.org/webpage/oracle-lReceived on Mon Feb 07 2011 - 11:59:44 CST