Re: silly dbms_stats question

From: Rakesh Tikku <rakesh.tikku_at_gmail.com>
Date: Fri, 24 Apr 2009 15:50:39 -0700
Message-ID: <4643fc610904241550g1784087awf130e025e79f9f12_at_mail.gmail.com>



in my experience, dbms_stats always updates the last_analyzed column.

Here is some related information:

In 10gR2, we have a new view called DBA_TAB_STATS_HISTORY that keeps a record (at the table level) about previous runs of dbms_stats. By default history is retained for 31 days. Can be changed using DBMS_STATS.ALTER_STATS_HISTORY_RETENTION(). There is no corresponding DBA_IND view for stat history for indexes.

Also, DBA_OPTSTAT_OPERATIONS stores the history of stats collection operations performed at the schema or database level.

hth.

Rakesh

Managing Principal
DB Perf Inc.
www.dbperf.com

On Fri, Apr 24, 2009 at 8:49 AM, Crisler, Jon <Jon.Crisler_at_usi.com> wrote:

> I have never been able to figure out what view shows when a table was
> last analyzed with DBMS_STATS in Oracle 10g.
>
> I know that dba_tables column “last_analyzed” does not reflect
> dbms_stats. DBA_TAB_MODIFICATIONS tracks monitoring for dbms_stats, but it
> does not track when dbms_stats was run.
>
>
>
> I am trying to write some queries to determine which tables need to have
> dbms_stats run more frequently, and I want to join dba_tab_modifications to
> the view that tracks the last dbms_stats run.
>
>
>
> Any ideas what view tracks last dbms_stats run on a table ?
> -- http://www.freelists.org/webpage/oracle-l

--
http://www.freelists.org/webpage/oracle-l
Received on Fri Apr 24 2009 - 17:50:39 CDT

Original text of this message