Implications of Setting Oracle9iR2s Statistics CollectionLevel

It's Dynamic

As with most of the new tuning parameters that Oracle is putting into their product, this parameter is dynamic. This means that you can set and unset it at any time. It is available for setting at the system level or at the session level. There is one small difference between dynamically changing this parameter for the system compared to changing it at the session level. If you modify this parameter for your particular session through the ALTER SESSION command, only certain advisories and statistics are affected. Take a look at the Session Affected column in the preceding matrix for what you will affect. If modified at the system level through the ALTER SYSTEM command, all advisories and statistics are affected for the database and every session.

It's Confusing

If you have any of the three parameters set in your SPFILE, that particular parameter setting will override the setting of the STATISTICS_LEVEL parameter. In order to use the STATISTICS_LEVEL parameter, you must reset the parameters you want the STATISTICS_LEVEL parameter to control.

To do this you should issue the following command:

ALTER SYSTEM RESET <parameter> SCOPE=SPFILE SID='*';

To Switch from SPFILE Control to STATISTICS_LEVEL Control

Under this example, I do not want to collect any statistics or advisories. I will take you through a current setting where I will show you that timed statistics are being collected even though the STATISTICS_LEVEL is set to BASIC. In order to not collect timed statistics, I will have to get rid of the SPFILE entry so that timed statistics is under complete control by the STATISTICS_LEVEL parameter.

Currently timed statistics are being collected

SELECT STATISTICS_NAME,
       SYSTEM_STATUS
  FROM v$statistics_level
 ORDER BY 1
/
                               System
Statistics Name                Status
------------------------------ ----------
Buffer Cache Advice            DISABLED
MTTR Advice                    DISABLED
PGA Advice                     DISABLED
Plan Execution Statistics      DISABLED
Segment Level Statistics       DISABLED
Shared Pool Advice             DISABLED
Timed OS Statistics            DISABLED
Timed Statistics               ENABLED

Currently I have timed_statistics under SPFILE control

SQL> show parameter timed_statistics
NAME                                 TYPE        VALUE
------------------------------------ ----------- ----------
timed_statistics                     boolean     TRUE

And my statistics level is set to BASIC

SQL> show parameter statistics_level
NAME                                 TYPE        VALUE
------------------------------------ ----------- -----------
statistics_level                     string      BASIC

Previous /  Next

Prev  [1] [2] [3] Next

Close    To Top
  • Prev Article-Database:
  • Next Article-Database:
  • Now: Tutorial for Web and Software Design > Database > Oracle > Database Content
    Photoshop Tutorial
     

    Special Effect

      3D Effect
      Photoshop Articles
    Programming Tutorial
     

    C/C++ Tutorial

      Visual Basic
      C# Tutorial
    Database Tutorial
     

    MySQL Tutorial

      MS SQL Tutorial
      Oracle Tutorial
    Geek Tutorial
     

    Blogging Tutorial

      RSS Tutorial
      Podcasting Tutorial
    Graphic Design Tutorial
      Coreldraw Tutorial
      Illustrator Tutorial
      3D Tutorials
    Webmaster Articles
     

    Domain Service

      Web Hosting
      Site Promotion
    Java Tutorial/ Articles
     

    Java Servlets

      JavaEE Tutorial
     

    JavaBeans Tutorial

    XML Tutorial/ Articles
     

    XML Style

      AJAX Tutorial
      XML Mobile
    Flash Tutorial/ Articles
     

    Flash Video

      Action Script
      Flash Articles
    OS Tutorial/ Articles
      Linux Tutorial
      Symbian Tutorial
      MacOS Tutorial
    Personal Tech
      Hardware Tutorial
      Software Tutorial
      Online Auction