Recommendation for row count of a VL Partitioned Table
DBAsupport.com Forums - Powered by vBulletin
Results 1 to 6 of 6

Thread: Recommendation for row count of a VL Partitioned Table

Hybrid View

  1. #1
    Join Date
    Mar 2006
    Location
    OH
    Posts
    6

    Recommendation for row count of a VL Partitioned Table

    We have a partitioned table that at last count had 6,683,071,020
    Rows.

    What is the best way in Oracle 9i to get a count of the total number of rows in this table and not impact performance too severerly? We are planning to upgrade to 10g but we are not there yet.

    Thanks.

  2. #2
    Join Date
    Sep 2002
    Location
    England
    Posts
    7,333
    you want accurate? then do a count, then analyze the table with a small estimate_percent and check out num_rows in user_tables

  3. #3
    Join Date
    Mar 2006
    Location
    OH
    Posts
    6
    On a weekly basis,
    I have been doing a SELECT COUNT(ROWID) FROM REALLY_BIG_TABLE;

    I'm concerned however. I'm afraid of what impact I may be having on the database performance in doing that. It takes a long time for a 6 billion row count to return.

    Is that the best way of getting accurate stats? Doing a count?

    I am new on the project at and plan to implement
    DBMS_STATS.GATHER_SCHEMA_STATS(VAR_CSCHEMA_NAME, DBMS_STATS.AUTO_SAMPLE_SIZE);

    I have not implemented that yet, Is that the best approach?

  4. #4
    Join Date
    Jun 2000
    Location
    Madrid, Spain
    Posts
    7,447
    How about add a parallel clause?

  5. #5
    Join Date
    Mar 2006
    Location
    OH
    Posts
    6
    Can you point me to a syntax reference to do that?
    Thanks.

  6. #6
    Join Date
    Aug 2002
    Location
    Colorado Springs
    Posts
    5,253
    If you have an index on the table, either a btree index on a nonnull comment or a bitmap index on any, then that can be used to get a row count.

    By the way count(rowid) means nothing other then count(*) ... Same thing.

    I'm disturbed that you are new on the project and planning to implement a statistics gathering job without fully understanding it, or presumably being aware of what gathering method has been used before.
    David Aldridge,
    "The Oracle Sponge"

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

    Oracle ACE

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