CREATE TABLE bm_cm_document (
    ID                                NUMBER(18, 0) ,
    PARENT_ID                         NUMBER(18, 0)     NOT NULL,
    PROCESS_ID                        NUMBER(18, 0)     NOT NULL,
    COMPANY_ID                        NUMBER(18, 0)     NOT NULL,
    LABEL                             VARCHAR2(1020),
    VARIABLE_NAME                     VARCHAR2(1020),
    TYPE_                             NUMBER(5, 0)  ,
    NUMBER_                           NUMBER(5, 0)  ,
    DESCRIPTION                       VARCHAR2(1020),
    DATE_ADDED                        DATE              NOT NULL,
    DATE_MODIFIED                     DATE          ,
    ORDER_BY_ATTR                     VARCHAR2(240)     NOT NULL,
    PRE_MODIFY_RULE_META_ID           NUMBER(18, 0) ,
    MODIFY_RULE_EXEC_POLICY           NUMBER(2, 0)      NOT NULL,
    AUTO_UPDATE_RULE_META_ID          NUMBER(18, 0) ,
    MASS_UPDATE_RULE_META_ID          NUMBER(18, 0) ,
    GUID                              VARCHAR2(4000)    NOT NULL,
    PRE_FORMULA_UPDATE_RULE_META      NUMBER(18, 0) ,
    POST_MODIFY_RULE_META_ID          NUMBER(18, 0) ,
    OPPORTUNITY_ID_MAPPING            VARCHAR2(1020),
    STD_SYS_OBJ                       NUMBER(1, 0)  ,
    STD_PRE_MODIFY_RULE               NUMBER(1, 0)  ,
    STD_PRE_FORMULA_RULE              NUMBER(1, 0)  ,
    STD_AUTO_UPDATE_RULE              NUMBER(1, 0)  ,
    STD_POST_MODIFY_RULE              NUMBER(1, 0)  ,
    COVERAGE_SUPPORT                  NUMBER(1, 0)  ,
    CVG_ORDER_NUM_MAP_ATTR_ID         NUMBER(18, 0) ,
    CVG_LINE_NUM_MAP_ATTR_ID          NUMBER(18, 0) ,
    CVG_UOM_MAP_ATTR_ID               NUMBER(18, 0) ,
    CVG_QUANTITY_MAP_ATTR_ID          NUMBER(18, 0) ,
    CVG_MAIN_ORDER_NUM_MAP_ATTR_ID    NUMBER(18, 0) ,
    CVG_CUSTOMER_ID_MAP_ATTR_ID       NUMBER(18, 0) ,
    CVG_STD_DEFAULT_OVERRIDE          NUMBER(1, 0)  ,
    ID                                NUMBER(18, 0) ,
    PARENT_ID                         NUMBER(18, 0)     NOT NULL,
    PROCESS_ID                        NUMBER(18, 0)     NOT NULL,
    COMPANY_ID                        NUMBER(18, 0)     NOT NULL,
    LABEL                             VARCHAR2(1020),
    VARIABLE_NAME                     VARCHAR2(1020),
    TYPE_                             NUMBER(5, 0)  ,
    NUMBER_                           NUMBER(5, 0)  ,
    DESCRIPTION                       VARCHAR2(1020),
    DATE_ADDED                        DATE              NOT NULL,
    DATE_MODIFIED                     DATE          ,
    ORDER_BY_ATTR                     VARCHAR2(240)     NOT NULL,
    PRE_MODIFY_RULE_META_ID           NUMBER(18, 0) ,
    MODIFY_RULE_EXEC_POLICY           NUMBER(2, 0)      NOT NULL,
    AUTO_UPDATE_RULE_META_ID          NUMBER(18, 0) ,
    MASS_UPDATE_RULE_META_ID          NUMBER(18, 0) ,
    GUID                              VARCHAR2(4000)    NOT NULL,
    PRE_FORMULA_UPDATE_RULE_META      NUMBER(18, 0) ,
    POST_MODIFY_RULE_META_ID          NUMBER(18, 0) ,
    OPPORTUNITY_ID_MAPPING            VARCHAR2(1020),
    STD_SYS_OBJ                       NUMBER(1, 0)  ,
    STD_PRE_MODIFY_RULE               NUMBER(1, 0)  ,
    STD_PRE_FORMULA_RULE              NUMBER(1, 0)  ,
    STD_AUTO_UPDATE_RULE              NUMBER(1, 0)  ,
    STD_POST_MODIFY_RULE              NUMBER(1, 0)  ,
    COVERAGE_SUPPORT                  NUMBER(1, 0)  ,
    CVG_ORDER_NUM_MAP_ATTR_ID         NUMBER(18, 0) ,
    CVG_LINE_NUM_MAP_ATTR_ID          NUMBER(18, 0) ,
    CVG_UOM_MAP_ATTR_ID               NUMBER(18, 0) ,
    CVG_QUANTITY_MAP_ATTR_ID          NUMBER(18, 0) ,
    CVG_MAIN_ORDER_NUM_MAP_ATTR_ID    NUMBER(18, 0) ,
    CVG_CUSTOMER_ID_MAP_ATTR_ID       NUMBER(18, 0) ,
    CVG_STD_DEFAULT_OVERRIDE          NUMBER(1, 0)  ,
    CONSTRAINT pk_bm_cm_document PRIMARY KEY (ID, ID)
);
