Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: Statistics stopping after a while
On Sat, 13 Apr 2002 19:58:17 +0200, Frederic Payant
<fpayant_at_club-internet.fr> wrote:
>hi,
>
>I was very happy discovering the package 'DBMS-STAT' because I hoped
>to do all my stats on a database with a (near) one liner like :
>sqlplus system/manager_at_plonk <<!!
>execute dbms_stat.DBMS_STATS.GATHER_DATABASE_STATS( cascade => TRUE);
>exit
>!!
>
>But I was really surprised when I saw that statistics was gathered
>only on one part (around 1/3 eg 100 tables) of tables of my main
>schema.
>I didn't see any things in doc indicating any limit on number or type
>of tables.
>And the package doesn't emit any error (but it could be my fault, may
>be I've something to do to have error messages printed on screen )
>
>Thanks for helping,
>Amicalement
>Frédéric PAYANT
If this is your complete command line it may be likely missing some
parameters, which have bad defaults.
Also, you should verify whether or not gather_database_stats wouldn't
analyze SYS. That would be a disastrous move, as the SYS schema has
been build in the past to follow RBO (which is one of the reasons
probably why RBO will stay indefinitely)
DBMS_STATS is definitely not the only way to collect statistics
automatically. dbms_utility has similar calls (analyze_database,
analyze_schema, analyze_object) which reproduce the ANALYZE command in
pl/sql
DBMS_STATS however can use parallel processing, can write to a
separate stats table, can gather statistics for stale objects only
(provided you use ALTER TABLE <table_name> MONITOR)
You can selectively import statistics in the dictionary etc.
There is no limit of any kind, I'm afraid you should come up with more
specific info.
-- Regards Sybrand Bakker, Senior Oracle DBA To reply remove -verwijderdit from my e-mail addressReceived on Sat Apr 13 2002 - 14:28:22 CDT