Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Mailing Lists -> Oracle-L -> Re: dbms_stats broken
Koivu, Lisa wrote:
> Hello everyone,
>
> Is anyone using dbms_stats and gather stale or gather auto in 9.2? I’m
> trying to use dbms_stats gather schema stats with the stale option and
> it just isn’t working in 8.1.7.4. This is documented on Metalink. I’d
> love to hear from someone else if this is fixed in 9.2 and if it can
> be reliably used.
>
> Thank you
>
> Lisa Monkey.
>
I run this sql out of a python program against a 9.2.0.2.0 database on a
Compaq Tru64 server. Works like a charm. The 'gather stale' option works
as well.
sql = "BEGIN DBMS_STATS.GATHER_SCHEMA_STATS(
ownname => '%s',
options => 'GATHER AUTO',
estimate_percent => dbms_stats.auto_sample_size,
method_opt => 'for all columns size auto',
cascade => true); END;" % schema
--Glenn Stauffer
-- Please see the official ORACLE-L FAQ: http://www.orafaq.net -- Author: Glenn Stauffer INET: stauffer_at_swarthmore.edu Fat City Network Services -- 858-538-5051 http://www.fatcity.com San Diego, California -- Mailing list and web hosting services --------------------------------------------------------------------- To REMOVE yourself from this mailing list, send an E-Mail message to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing).Received on Thu May 29 2003 - 07:56:48 CDT