Re: Analyze tables+ind
Date: Wed, 19 Nov 2008 01:08:39 -0800 (PST)
Message-ID: <8a031238-ecc4-4e6e-9a4b-e6e84ced06ba@d10g2000pra.googlegroups.com>
On 19 nov, 09:38, "timo" <timo.ta..._at_luukku.com> wrote:
> Hi,
> I'd like to analyze one schema's all tables and indexes every night - should
> I implement a PL/SQL-procedure for this and add it to Database
> Control/Scheduler Jobs ? - there seems to some "gather stats"-jobs already
> but those are "smart-ones" and this one schema is vital an stats must in
> up-to-date.
>
> BR,
> Timo
Those jobs are smart enough to do that. In fact your job may screw
this all up.
You can easily check whether you have up-to-date statistics by looking
at the last_analyzed_data in dba_tables etc.
Generally speaking daily analysis is a bad idea and decreases the
chance you have stable execution plans. You would better set up proper
statistics and lock them.
-- Sybrand Bakker Senior Oracle DBAReceived on Wed Nov 19 2008 - 03:08:39 CST