Home » SQL & PL/SQL » SQL & PL/SQL » How to use DBMS_Stats (Oracle 10g)
How to use DBMS_Stats [message #311121] Thu, 03 April 2008 08:10 Go to next message
brandond
Messages: 20
Registered: March 2008
Junior Member
I'm needing to update statistics on all of my tables in a schema, but am unsure how to use dbms_stats. It hasn't been run on my database in awhile, and I need to review stats on the tables, but am unsure how to make this happen.

Also, along with what code to put in sql+ what do I need to be logged in as?

Thanks
Re: How to use DBMS_Stats [message #311132 is a reply to message #311121] Thu, 03 April 2008 09:10 Go to previous messageGo to next message
BlackSwan
Messages: 25045
Registered: January 2009
Location: SoCal
Senior Member
SQL> DESC DBMS_STATS

PROCEDURE GATHER_SCHEMA_STATS
 Argument Name                  Type                    In/Out Default?
 ------------------------------ ----------------------- ------ --------
 OWNNAME                        VARCHAR2                IN
 ESTIMATE_PERCENT               NUMBER                  IN     DEFAULT
 BLOCK_SAMPLE                   BOOLEAN                 IN     DEFAULT
 METHOD_OPT                     VARCHAR2                IN     DEFAULT
 DEGREE                         NUMBER                  IN     DEFAULT
 GRANULARITY                    VARCHAR2                IN     DEFAULT
 CASCADE                        BOOLEAN                 IN     DEFAULT
 STATTAB                        VARCHAR2                IN     DEFAULT
 STATID                         VARCHAR2                IN     DEFAULT
 OPTIONS                        VARCHAR2                IN     DEFAULT
 STATOWN                        VARCHAR2                IN     DEFAULT
 NO_INVALIDATE                  BOOLEAN                 IN     DEFAULT
 GATHER_TEMP                    BOOLEAN                 IN     DEFAULT
 GATHER_FIXED                   BOOLEAN                 IN     DEFAULT
 STATTYPE                       VARCHAR2                IN     DEFAULT
 FORCE                          BOOLEAN                 IN     DEFAULT
Re: How to use DBMS_Stats [message #311133 is a reply to message #311121] Thu, 03 April 2008 09:11 Go to previous message
Michel Cadot
Messages: 64132
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
DBMS_STATS

Regards
Michel
Previous Topic: Is indexes are not used if the pl/sql tables are refered in the where clause?
Next Topic: Query Problem: Populating more than required number of rows
Goto Forum:
  


Current Time: Wed Dec 07 18:40:42 CST 2016

Total time taken to generate the page: 0.11171 seconds