DBAsupport.com Forums - Powered by vBulletin
Results 1 to 5 of 5

Thread: Collecting statistics with compute or estimate

  1. #1
    Join Date
    Mar 2004
    Location
    IA USA
    Posts
    257

    Collecting statistics with compute or estimate

    Hi DBAs,

    The scenario is like this:
    We got a trouble 9I OLTP database. We try to decide the statistics collection strategy.
    The data size is not too big. around 20g right now.
    I was thinking:weekly such as every Saturday collect the statistics with compute method.
    But our consultant thinks use estimate is okay.
    Never do more unnecessary statistics collection work.

    Does the method -compute or estimate really matter?
    How oracle samples the 10% when it does the computing statistics?

    Thanks,

    Lily
    Last edited by Lily_Liu_2004; 01-08-2007 at 06:43 PM.

  2. #2
    Join Date
    Aug 2002
    Location
    Colorado Springs
    Posts
    5,253
    When estimating statistics Oracle uses the SAMPLE clause on the select statements, which is documented in the SQL reference.

    Compare the results you get with compute and estimate to see how accurate the estimation is. You can probably go down to 5% or less and still get good stats.
    David Aldridge,
    "The Oracle Sponge"

    Senior Manager, Business Intelligence Development
    XM Satellite Radio
    Washington, DC

    Oracle ACE

  3. #3
    Join Date
    Jun 2006
    Location
    Chennai, INDIA
    Posts
    72

    Wink

    Hi
    Use DBMS_STATS package. Its more accurate than ANALYZE. Anyway ANALYZE will not be there in future releases. DBMS_STATS package is good.

  4. #4
    Join Date
    Nov 2000
    Location
    Birmingham, UK
    Posts
    360
    Turn monitoring on for your tables then use dbms_stats with the GATHER STALE option to compute stats on any tables that have stale stats (ones with > 10% of DML on the rows - see DBA_TAB_MODIFICATIONS).
    Set up a job to run at appropriate times for your system e.g. before online day, before batch window etc.
    You now will only run stats on the tables that need them
    HTH

  5. #5
    Join Date
    Nov 2000
    Location
    greenwich.ct.us
    Posts
    9,092

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Click Here to Expand Forum to Full Width