-- ====================================================================
-- A_TABLE_STAT_HIST Table
-- ====================================================================
-- Purpose: Store historical table statistics for trend analysis
-- ====================================================================

CREATE TABLE CT_MRDS.A_TABLE_STAT_HIST (
    A_TABLE_STAT_HIST_KEY             NUMBER(38,0) PRIMARY KEY, 
    A_SOURCE_FILE_CONFIG_KEY          NUMBER(38,0) NOT NULL,
    TABLE_NAME                        VARCHAR2(200) NOT NULL,
    FILE_COUNT                        NUMBER(38,0),
    OVER_ARCH_THRESOLD_FILE_COUNT     NUMBER(38,0),
    ROW_COUNT                         NUMBER(38,0), 
    OVER_ARCH_THRESOLD_ROW_COUNT      NUMBER(38,0), 
    SIZE                              NUMBER(38,0),
    OVER_ARCH_THRESOLD_SIZE           NUMBER(38,0),
    ARCH_THRESHOLD_DAYS               NUMBER(4,0),
    CREATED                           TIMESTAMP(6) DEFAULT SYSTIMESTAMP
) TABLESPACE "DATA";