Please wait. This can take some minutes ...
Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance.
Project price only 1 $
You can buy this project and download/modify it how often you want.
sql.oracle.ole-master-sql.sql Maven / Gradle / Ivy
-----------------------------------------------------------------------------
-- AP_AUTO_APRV_EXCL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AP_AUTO_APRV_EXCL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AP_AUTO_APRV_EXCL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AP_AUTO_APRV_EXCL_T
(
FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT AP_AUTO_APRV_EXCL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AP_AUTO_APRV_EXCL_T
ADD CONSTRAINT AP_AUTO_APRV_EXCL_TP1
PRIMARY KEY (FIN_COA_CD,ACCOUNT_NBR)
/
-----------------------------------------------------------------------------
-- AP_CRDT_MEMO_ACCT_CHG_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AP_CRDT_MEMO_ACCT_CHG_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AP_CRDT_MEMO_ACCT_CHG_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AP_CRDT_MEMO_ACCT_CHG_T
(
CRDT_MEMO_ACCT_CHG_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CRDT_MEMO_ITM_ID NUMBER(10)
, FIN_COA_CD VARCHAR2(2) NOT NULL
, ACCOUNT_NBR VARCHAR2(7) NOT NULL
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_OBJECT_CD VARCHAR2(4) NOT NULL
, FIN_SUB_OBJ_CD VARCHAR2(3)
, PROJECT_CD VARCHAR2(10)
, ORG_REFERENCE_ID VARCHAR2(8)
, ITM_ACCT_TOT_AMT NUMBER(19,2) NOT NULL
, ACLN_PCT NUMBER(35,20) NOT NULL
, CRDT_MEMO_ACCT_CHG_TS DATE NOT NULL
, FDOC_POST_YR NUMBER(4)
, FDOC_POST_PRD_CD VARCHAR2(2)
, CONSTRAINT AP_CRDT_MEMO_ACCT_CHG_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AP_CRDT_MEMO_ACCT_CHG_T
ADD CONSTRAINT AP_CRDT_MEMO_ACCT_CHG_TP1
PRIMARY KEY (CRDT_MEMO_ACCT_CHG_ID)
/
CREATE INDEX AP_CRDT_MEMO_ACCT_CHG_TI1
ON AP_CRDT_MEMO_ACCT_CHG_T
(CRDT_MEMO_ACCT_CHG_TS)
/
CREATE INDEX AP_CRDT_MEMO_ACCT_CHG_TI2
ON AP_CRDT_MEMO_ACCT_CHG_T
(CRDT_MEMO_ITM_ID)
/
-----------------------------------------------------------------------------
-- AP_CRDT_MEMO_ACCT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AP_CRDT_MEMO_ACCT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AP_CRDT_MEMO_ACCT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AP_CRDT_MEMO_ACCT_T
(
CRDT_MEMO_ACCT_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CRDT_MEMO_ITM_ID NUMBER(10)
, FIN_COA_CD VARCHAR2(2) NOT NULL
, ACCOUNT_NBR VARCHAR2(7) NOT NULL
, FIN_OBJECT_CD VARCHAR2(4) NOT NULL
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, PROJECT_CD VARCHAR2(10)
, ORG_REFERENCE_ID VARCHAR2(8)
, ITM_ACCT_TOT_AMT NUMBER(19,2) NOT NULL
, ACLN_PCT NUMBER(35,20) NOT NULL
, FDOC_LINE_NBR NUMBER(7)
, CONSTRAINT AP_CRDT_MEMO_ACCT_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AP_CRDT_MEMO_ACCT_T
ADD CONSTRAINT AP_CRDT_MEMO_ACCT_TP1
PRIMARY KEY (CRDT_MEMO_ACCT_ID)
/
CREATE INDEX AP_CRDT_MEMO_ACCT_TI1
ON AP_CRDT_MEMO_ACCT_T
(CRDT_MEMO_ITM_ID)
/
-----------------------------------------------------------------------------
-- AP_CRDT_MEMO_ITM_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AP_CRDT_MEMO_ITM_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AP_CRDT_MEMO_ITM_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AP_CRDT_MEMO_ITM_T
(
CRDT_MEMO_ITM_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CRDT_MEMO_ID NUMBER(9) NOT NULL
, ITM_LN_NBR NUMBER(4)
, ITM_TYP_CD VARCHAR2(4) NOT NULL
, ITM_CRDT_QTY NUMBER(11,2)
, ITM_UNT_PRC NUMBER(19,4)
, ITM_EXTND_PRC NUMBER(19,2)
, ITM_ASND_TO_TRADE_IN_IND VARCHAR2(1)
, ITM_DESC VARCHAR2(4000)
, PO_INV_TOT_QTY NUMBER(11,2)
, PO_UNT_PRC NUMBER(19,4)
, PO_EXTND_PRC NUMBER(19,2)
, PMT_RQST_INV_TOT_QTY NUMBER(11,2)
, PMT_RQST_UNT_PRC NUMBER(19,4)
, PMT_RQST_EXTND_PRC NUMBER(19,2)
, ITM_TAX_AMT NUMBER(19,4)
, CPTL_AST_TRN_TYP_CD VARCHAR2(4)
, OLE_FOR_DISCNT_TYP VARCHAR2(1)
, OLE_FOR_DISCNT NUMBER(19,4)
, OLE_FOR_LST_PRC NUMBER(19,4)
, OLE_FOR_DISCNT_AMT NUMBER(19,4)
, OLE_FOR_UNT_CST NUMBER(19,4)
, OLE_EXCHANGE_RT NUMBER(19,6)
, OLE_CON_CST NUMBER(19,4)
, OLE_DOCUMENT_UUID VARCHAR2(50)
, CONSTRAINT AP_CRDT_MEMO_ITM_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AP_CRDT_MEMO_ITM_T
ADD CONSTRAINT AP_CRDT_MEMO_ITM_TP1
PRIMARY KEY (CRDT_MEMO_ITM_ID)
/
CREATE INDEX AP_CRDT_MEMO_ITM_TI1
ON AP_CRDT_MEMO_ITM_T
(CRDT_MEMO_ID)
/
-----------------------------------------------------------------------------
-- AP_CRDT_MEMO_ITM_USE_TAX_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AP_CRDT_MEMO_ITM_USE_TAX_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AP_CRDT_MEMO_ITM_USE_TAX_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AP_CRDT_MEMO_ITM_USE_TAX_T
(
CRDT_MEMO_ITM_USE_TAX_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CRDT_MEMO_ITM_ID NUMBER(10)
, RATE_CD VARCHAR2(10) NOT NULL
, TAX_AMT NUMBER(19,4)
, FIN_COA_CD VARCHAR2(2) NOT NULL
, ACCOUNT_NBR VARCHAR2(7) NOT NULL
, FIN_OBJECT_CD VARCHAR2(4) NOT NULL
, CONSTRAINT AP_CRDT_MEMO_ITM_USE_TAX_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AP_CRDT_MEMO_ITM_USE_TAX_T
ADD CONSTRAINT AP_CRDT_MEMO_ITM_USE_TAX_TP1
PRIMARY KEY (CRDT_MEMO_ITM_USE_TAX_ID)
/
-----------------------------------------------------------------------------
-- AP_CRDT_MEMO_STAT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AP_CRDT_MEMO_STAT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AP_CRDT_MEMO_STAT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AP_CRDT_MEMO_STAT_T
(
CRDT_MEMO_STAT_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CRDT_MEMO_STAT_DESC VARCHAR2(45) NOT NULL
, CONSTRAINT AP_CRDT_MEMO_STAT_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AP_CRDT_MEMO_STAT_T
ADD CONSTRAINT AP_CRDT_MEMO_STAT_TP1
PRIMARY KEY (CRDT_MEMO_STAT_CD)
/
-----------------------------------------------------------------------------
-- AP_CRDT_MEMO_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AP_CRDT_MEMO_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AP_CRDT_MEMO_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AP_CRDT_MEMO_T
(
CRDT_MEMO_ID NUMBER(9)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_NBR VARCHAR2(14) NOT NULL
, VNDR_HDR_GNRTD_ID NUMBER(10) NOT NULL
, VNDR_DTL_ASND_ID NUMBER(10) NOT NULL
, VNDR_CUST_NBR VARCHAR2(30)
, VNDR_NM VARCHAR2(45)
, VNDR_LN1_ADDR VARCHAR2(45)
, VNDR_LN2_ADDR VARCHAR2(45)
, VNDR_CTY_NM VARCHAR2(45)
, VNDR_ST_CD VARCHAR2(2)
, INV_RQST_ID NUMBER(9)
, VNDR_PSTL_CD VARCHAR2(20)
, VNDR_CNTRY_CD VARCHAR2(2)
, PO_ID NUMBER(9)
, PO_ENCUM_FSCL_YR NUMBER(4)
, PMT_RQST_ID NUMBER(9)
, CRDT_MEMO_STAT_CD VARCHAR2(4)
, CRDT_MEMO_NBR VARCHAR2(35)
, CRDT_MEMO_DT DATE NOT NULL
, CRDT_MEMO_AMT NUMBER(19,2) NOT NULL
, CRDT_MEMO_NTE_LN1_TXT VARCHAR2(90)
, CRDT_MEMO_NTE_LN2_TXT VARCHAR2(90)
, CRDT_MEMO_NTE_LN3_TXT VARCHAR2(90)
, CRDT_MEMO_PD_TS DATE
, CRDT_HLD_IND VARCHAR2(1) default 'N' NOT NULL
, AP_PRCSR_ID VARCHAR2(40) NOT NULL
, PRCS_CMP_CD VARCHAR2(2) NOT NULL
, AP_APRVL_DT DATE
, ITM_MISC_CRDT_DESC VARCHAR2(255)
, CRDT_MEMO_EXTRT_DT DATE
, AP_PUR_DOC_LNK_ID NUMBER(10)
, AP_HLD_ID VARCHAR2(40)
, CONT_ACCT_IND VARCHAR2(1)
, CLOSE_PO_IND VARCHAR2(1)
, REOPEN_PO_IND VARCHAR2(1)
, VNDR_ADDR_INTL_PROV_NM VARCHAR2(45)
, USE_TAX_IND VARCHAR2(1) default 'Y' NOT NULL
, BNK_CD VARCHAR2(4)
, VNDR_ATTN_NM VARCHAR2(45)
, ACCT_DISTR_MTD_IND VARCHAR2(1) default 'P' NOT NULL
, CRDT_MEMO_INV_TYP_ID NUMBER(10)
, CRDT_MEMO_INV_SUB_TYP_ID NUMBER(10)
, CRDT_PMT_MTHD_ID NUMBER(10)
, OLE_PR_BY VARCHAR2(50)
, CONSTRAINT AP_CRDT_MEMO_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AP_CRDT_MEMO_T
ADD CONSTRAINT AP_CRDT_MEMO_TP1
PRIMARY KEY (CRDT_MEMO_ID)
/
CREATE INDEX AP_CRDT_MEMO_TI1
ON AP_CRDT_MEMO_T
(PO_ID)
/
CREATE INDEX AP_CRDT_MEMO_TI2
ON AP_CRDT_MEMO_T
(CRDT_MEMO_STAT_CD)
/
CREATE INDEX AP_CRDT_MEMO_TI3
ON AP_CRDT_MEMO_T
(PMT_RQST_ID)
/
CREATE INDEX AP_CRDT_MEMO_TI4
ON AP_CRDT_MEMO_T
(VNDR_HDR_GNRTD_ID, VNDR_DTL_ASND_ID)
/
CREATE INDEX AP_CRDT_MEMO_TI6
ON AP_CRDT_MEMO_T
(FDOC_NBR)
/
CREATE INDEX AP_CRDT_MEMO_TI7
ON AP_CRDT_MEMO_T
(AP_PUR_DOC_LNK_ID)
/
-----------------------------------------------------------------------------
-- AP_ELCTRNC_INV_LOAD_SUM_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AP_ELCTRNC_INV_LOAD_SUM_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AP_ELCTRNC_INV_LOAD_SUM_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AP_ELCTRNC_INV_LOAD_SUM_T
(
INV_LOAD_SUM_ID NUMBER(14)
, VNDR_DUNS_NBR VARCHAR2(50)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FL_PROC_DT DATE NOT NULL
, INV_LOAD_SCCSS_CNT NUMBER(4)
, INV_LOAD_SCCSS_AMT NUMBER(19,4)
, INV_LOAD_FAIL_CNT NUMBER(4)
, INV_LOAD_FAIL_AMT NUMBER(19,4)
, CONSTRAINT AP_ELCTRNC_INV_LOAD_SUM_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AP_ELCTRNC_INV_LOAD_SUM_T
ADD CONSTRAINT AP_ELCTRNC_INV_LOAD_SUM_TP1
PRIMARY KEY (INV_LOAD_SUM_ID,VNDR_DUNS_NBR)
/
-----------------------------------------------------------------------------
-- AP_ELCTRNC_INV_MAP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AP_ELCTRNC_INV_MAP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AP_ELCTRNC_INV_MAP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AP_ELCTRNC_INV_MAP_T
(
AP_ELCTRNC_INV_MAP_ID NUMBER(8)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, VNDR_HDR_GNRTD_ID NUMBER(10)
, VNDR_DTL_ASND_ID NUMBER(10)
, INV_ITM_TYP_CD VARCHAR2(11)
, ITM_TYP_CD VARCHAR2(4)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1)
, CONSTRAINT AP_ELCTRNC_INV_MAP_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AP_ELCTRNC_INV_MAP_T
ADD CONSTRAINT AP_ELCTRNC_INV_MAP_TP1
PRIMARY KEY (AP_ELCTRNC_INV_MAP_ID)
/
-----------------------------------------------------------------------------
-- AP_ELCTRNC_INV_RJT_DOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AP_ELCTRNC_INV_RJT_DOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AP_ELCTRNC_INV_RJT_DOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AP_ELCTRNC_INV_RJT_DOC_T
(
INV_RJT_ID NUMBER(9)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, INV_LOAD_SUM_ID NUMBER(14)
, INV_PROC_DT DATE NOT NULL
, INV_FL_NM VARCHAR2(200)
, VNDR_DUNS_NBR VARCHAR2(50)
, VNDR_HDR_GNRTD_ID NUMBER(10)
, VNDR_DTL_ASND_ID NUMBER(10)
, INV_FL_DT_TXT VARCHAR2(100)
, INV_FL_NBR VARCHAR2(100)
, INV_FL_PRPS_ID VARCHAR2(50)
, INV_FL_OPRN_ID VARCHAR2(50)
, INV_FL_DPLMNT_MODE_VAL VARCHAR2(50)
, INV_FL_HDR_TYP_IND VARCHAR2(1) NOT NULL
, INV_FL_INFO_ONLY_IND VARCHAR2(1) NOT NULL
, INV_FL_TAX_IN_LN_IND VARCHAR2(1) NOT NULL
, INV_FL_SPCL_HANDLG_IN_LN_IND VARCHAR2(1) NOT NULL
, INV_FL_SHP_IN_LN_IND VARCHAR2(1) NOT NULL
, INV_FL_DSCT_IN_LN_IND VARCHAR2(1) NOT NULL
, INV_ORD_REF_ORD_ID VARCHAR2(100)
, INV_ORD_REF_DOC_REF_PYLD_ID VARCHAR2(100)
, INV_ORD_REF_DOC_REF_TXT VARCHAR2(100)
, INV_ORD_MSTR_AGRMN_REF_ID VARCHAR2(100)
, INV_ORD_MSTR_AGRMN_REF_DT_TXT VARCHAR2(100)
, INV_ORD_MSTR_AGRMN_INFO_ID VARCHAR2(100)
, INV_ORD_MSTR_AGRMN_INFO_DT_TXT VARCHAR2(100)
, INV_ORD_PO_ORD_ID VARCHAR2(100)
, INV_ORD_PO_ORD_DT_TXT VARCHAR2(100)
, INV_ORD_SUPP_ORD_INFO_ID VARCHAR2(100)
, PO_ID NUMBER(9)
, INV_ITM_SUB_TOT_AMT NUMBER(19,4)
, INV_ITM_SUB_TOT_CRNCY_CD VARCHAR2(20)
, INV_ITM_SPCL_HANDLG_AMT NUMBER(19,4)
, INV_ITM_SPCL_HANDLG_CRNCY_CD VARCHAR2(20)
, INV_ITM_SHP_AMT NUMBER(19,4)
, INV_ITM_SHP_CRNCY_CD VARCHAR2(20)
, INV_ITM_SHP_DESC VARCHAR2(300)
, INV_ITM_TAX_AMT NUMBER(19,4)
, INV_ITM_TAX_CRNCY_CD VARCHAR2(20)
, INV_ITM_TAX_DESC VARCHAR2(300)
, INV_ITM_GRS_AMT NUMBER(19,4)
, INV_ITM_GRS_CRNCY_CD VARCHAR2(20)
, INV_ITM_DSCT_AMT NUMBER(19,4)
, INV_ITM_DSCT_CRNCY_CD VARCHAR2(20)
, INV_ITM_NET_AMT NUMBER(19,4)
, INV_ITM_NET_CRNCY_CD VARCHAR2(20)
, INV_RJT_EXTRT_DT DATE
, PO_DLVY_CMP_CD VARCHAR2(2)
, INV_SHP_DT_TXT VARCHAR2(100)
, INV_ADDR_NM VARCHAR2(100)
, INV_SHP_TO_LN1_ADDR VARCHAR2(200)
, INV_SHP_TO_LN2_ADDR VARCHAR2(200)
, INV_SHP_TO_LN3_ADDR VARCHAR2(200)
, INV_CUST_NBR VARCHAR2(50)
, INV_SHP_TO_ST_CD VARCHAR2(200)
, INV_SHP_TO_CNTRY_CD VARCHAR2(200)
, INV_SHP_TO_CTY_NM VARCHAR2(200)
, INV_SHP_TO_PSTL_CD VARCHAR2(200)
, INV_PO_NBR VARCHAR2(100)
, INV_SHP_TO_CNTRY_NM VARCHAR2(200)
, INV_SHP_TO_ADDR_TYP_NM VARCHAR2(30)
, INV_BILL_TO_ADDR_NM VARCHAR2(100)
, INV_BILL_TO_LN1_ADDR VARCHAR2(200)
, INV_BILL_TO_LN2_ADDR VARCHAR2(200)
, INV_BILL_TO_LN3_ADDR VARCHAR2(200)
, INV_BILL_TO_CTY_NM VARCHAR2(200)
, INV_BILL_TO_ST_CD VARCHAR2(200)
, INV_BILL_TO_PSTL_CD VARCHAR2(200)
, INV_BILL_TO_CNTRY_CD VARCHAR2(200)
, INV_BILL_TO_CNTRY_NM VARCHAR2(200)
, INV_BILL_TO_ADDR_TYP_NM VARCHAR2(30)
, INV_RMT_TO_ADDR_NM VARCHAR2(100)
, INV_RMT_TO_LN1_ADDR VARCHAR2(200)
, INV_RMT_TO_LN2_ADDR VARCHAR2(200)
, INV_RMT_TO_LN3_ADDR VARCHAR2(200)
, INV_RMT_TO_CTY_NM VARCHAR2(200)
, INV_RMT_TO_ST_CD VARCHAR2(200)
, INV_RMT_TO_PSTL_CD VARCHAR2(50)
, INV_RMT_TO_CNTRY_CD VARCHAR2(200)
, INV_RMT_TO_CNTRY_NM VARCHAR2(200)
, INV_RMT_TO_ADDR_TYP_NM VARCHAR2(30)
, FDOC_NBR VARCHAR2(14) NOT NULL
, AP_PUR_DOC_LNK_ID NUMBER(10)
, INV_NUM_ACPT_IND VARCHAR2(1)
, INV_RJT_RSRCH_IND VARCHAR2(1)
, AP_APRVL_DT DATE
, PREQ_ID NUMBER(9)
, CONSTRAINT AP_ELCTRNC_INV_HDR_INFO_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AP_ELCTRNC_INV_RJT_DOC_T
ADD CONSTRAINT AP_ELCTRNC_INV_RJT_DOC_TP1
PRIMARY KEY (INV_RJT_ID)
/
CREATE INDEX AP_ELCTRNC_INV_RJT_DOC_TI1
ON AP_ELCTRNC_INV_RJT_DOC_T
(INV_LOAD_SUM_ID, VNDR_DUNS_NBR)
/
CREATE INDEX AP_ELCTRNC_INV_RJT_DOC_TI2
ON AP_ELCTRNC_INV_RJT_DOC_T
(AP_PUR_DOC_LNK_ID)
/
CREATE INDEX AP_ELCTRNC_INV_RJT_DOC_TI3
ON AP_ELCTRNC_INV_RJT_DOC_T
(FDOC_NBR)
/
-----------------------------------------------------------------------------
-- AP_ELCTRNC_INV_RJT_ITM_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AP_ELCTRNC_INV_RJT_ITM_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AP_ELCTRNC_INV_RJT_ITM_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AP_ELCTRNC_INV_RJT_ITM_T
(
INV_RJT_ITM_ID NUMBER(9)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, INV_RJT_ID NUMBER(9) NOT NULL
, INV_ITM_LN_NBR NUMBER(4)
, INV_ITM_QTY NUMBER(11,4)
, INV_ITM_UOM_CD VARCHAR2(4)
, INV_ITM_UNIT_PRC NUMBER(19,4)
, INV_ITM_UNIT_PRC_CRNCY_CD VARCHAR2(20)
, INV_ITM_SUB_TOT_AMT NUMBER(19,4)
, INV_ITM_SUB_TOT_CRNCY_CD VARCHAR2(20)
, INV_ITM_SPCL_HANDLG_AMT NUMBER(19,4)
, INV_ITM_SPCL_HANDLG_CRNCY_CD VARCHAR2(20)
, INV_ITM_SHP_AMT NUMBER(19,4)
, INV_ITM_SHP_CRNCY_CD VARCHAR2(20)
, INV_ITM_SHP_DESC VARCHAR2(300)
, INV_ITM_TAX_AMT NUMBER(19,4)
, INV_ITM_TAX_CRNCY_CD VARCHAR2(20)
, INV_ITM_TAX_DESC VARCHAR2(300)
, INV_ITM_GRS_AMT NUMBER(19,4)
, INV_ITM_GRS_CRNCY_CD VARCHAR2(20)
, INV_ITM_DSCT_AMT NUMBER(19,4)
, INV_ITM_DSCT_CRNCY_CD VARCHAR2(20)
, INV_ITM_NET_AMT NUMBER(19,4)
, INV_ITM_NET_CRNCY_CD VARCHAR2(20)
, INV_REF_ITM_LN_NBR NUMBER(4)
, INV_REF_ITM_SERIAL_NBR VARCHAR2(100)
, INV_REF_ITM_SUPP_PART_ID VARCHAR2(100)
, INV_REF_ITM_SUPP_PART_AUX_ID VARCHAR2(100)
, INV_REF_ITM_DESC VARCHAR2(400)
, INV_REF_ITM_MFR_PART_ID VARCHAR2(100)
, INV_REF_ITM_MFR_NM VARCHAR2(100)
, INV_REF_ITM_CNTRY_CD VARCHAR2(50)
, INV_REF_ITM_CNTRY_NM VARCHAR2(100)
, INV_CATLG_NBR VARCHAR2(50)
, INV_UOM_ACPT_IND VARCHAR2(1)
, INV_CATLG_NBR_ACPT_IND VARCHAR2(1)
, CONSTRAINT AP_ELCTRNC_INV_RJT_ITM_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AP_ELCTRNC_INV_RJT_ITM_T
ADD CONSTRAINT AP_ELCTRNC_INV_RJT_ITM_TP1
PRIMARY KEY (INV_RJT_ITM_ID)
/
CREATE INDEX AP_ELCTRNC_INV_RJT_ITM_TI1
ON AP_ELCTRNC_INV_RJT_ITM_T
(INV_RJT_ID)
/
-----------------------------------------------------------------------------
-- AP_ELCTRNC_INV_RJT_REAS_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AP_ELCTRNC_INV_RJT_REAS_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AP_ELCTRNC_INV_RJT_REAS_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AP_ELCTRNC_INV_RJT_REAS_T
(
INV_RJT_REAS_ID NUMBER(9)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, INV_RJT_ID NUMBER(9) NOT NULL
, INV_RJT_REAS_TYP_CD VARCHAR2(4) NOT NULL
, INV_RJT_REAS_DESC VARCHAR2(400) NOT NULL
, INV_FL_NM VARCHAR2(200)
, CONSTRAINT AP_ELCTRNC_INV_RJT_REAS_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AP_ELCTRNC_INV_RJT_REAS_T
ADD CONSTRAINT AP_ELCTRNC_INV_RJT_REAS_TP1
PRIMARY KEY (INV_RJT_REAS_ID)
/
CREATE INDEX AP_ELCTRNC_INV_RJT_REAS_TI1
ON AP_ELCTRNC_INV_RJT_REAS_T
(INV_RJT_REAS_TYP_CD)
/
CREATE INDEX AP_ELCTRNC_INV_RJT_REAS_TI2
ON AP_ELCTRNC_INV_RJT_REAS_T
(INV_RJT_ID)
/
-----------------------------------------------------------------------------
-- AP_ELCTRNC_INV_RJT_REAS_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AP_ELCTRNC_INV_RJT_REAS_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AP_ELCTRNC_INV_RJT_REAS_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AP_ELCTRNC_INV_RJT_REAS_TYP_T
(
INV_RJT_REAS_TYP_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, INV_RJT_REAS_TYP_DESC VARCHAR2(200)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, INV_FAIL_IND VARCHAR2(1)
, INV_RJT_REAS_PERF_MTCH_IND VARCHAR2(1)
, CONSTRAINT AP_ELCTRNC_INV_RJT_TYP_CD_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AP_ELCTRNC_INV_RJT_REAS_TYP_T
ADD CONSTRAINT AP_ELCTRNC_INV_RJT_REAS_TYPP1
PRIMARY KEY (INV_RJT_REAS_TYP_CD)
/
-----------------------------------------------------------------------------
-- AP_NEG_PMT_RQST_APRVL_LMT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AP_NEG_PMT_RQST_APRVL_LMT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AP_NEG_PMT_RQST_APRVL_LMT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AP_NEG_PMT_RQST_APRVL_LMT_T
(
AP_NEG_PMT_RQST_APRVL_LMT_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FIN_COA_CD VARCHAR2(2) NOT NULL
, ORG_CD VARCHAR2(4)
, ACCT_NBR VARCHAR2(7)
, NEG_PMT_RQST_APRVL_LMT_AMT NUMBER(19,2)
, ACTV_IND VARCHAR2(1) default 'Y'
, CONSTRAINT AP_NEG_PMT_RQST_APRVL_LMT_TC0 UNIQUE (OBJ_ID)
, CONSTRAINT AP_NEG_PMT_RQST_APRVL_LMT_TC1 UNIQUE (FIN_COA_CD, ORG_CD, ACCT_NBR)
)
/
ALTER TABLE AP_NEG_PMT_RQST_APRVL_LMT_T
ADD CONSTRAINT AP_NEG_PMT_RQST_APRVL_LMT_TP1
PRIMARY KEY (AP_NEG_PMT_RQST_APRVL_LMT_ID)
/
-----------------------------------------------------------------------------
-- AP_PMT_RQST_ACCT_CHG_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AP_PMT_RQST_ACCT_CHG_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AP_PMT_RQST_ACCT_CHG_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AP_PMT_RQST_ACCT_CHG_T
(
PMT_RQST_ACCT_CHG_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, PMT_RQST_ITM_ID NUMBER(10)
, FIN_COA_CD VARCHAR2(2) NOT NULL
, ACCOUNT_NBR VARCHAR2(7) NOT NULL
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_OBJECT_CD VARCHAR2(4) NOT NULL
, FIN_SUB_OBJ_CD VARCHAR2(3)
, PROJECT_CD VARCHAR2(10)
, ORG_REFERENCE_ID VARCHAR2(8)
, ITM_ACCT_TOT_AMT NUMBER(19,2) NOT NULL
, ACLN_PCT NUMBER(35,20)
, PMT_RQST_ACCT_CHG_TS DATE NOT NULL
, FDOC_POST_YR NUMBER(4)
, FDOC_POST_PRD_CD VARCHAR2(2)
, OLE_DISENC_AMT NUMBER(19,2) NOT NULL
, CONSTRAINT AP_PMT_RQST_ACCT_CHG_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AP_PMT_RQST_ACCT_CHG_T
ADD CONSTRAINT AP_PMT_RQST_ACCT_CHG_TP1
PRIMARY KEY (PMT_RQST_ACCT_CHG_ID)
/
CREATE INDEX AP_PMT_RQST_ACCT_CHG_TI1
ON AP_PMT_RQST_ACCT_CHG_T
(PMT_RQST_ACCT_CHG_TS)
/
CREATE INDEX AP_PMT_RQST_ACCT_CHG_TI2
ON AP_PMT_RQST_ACCT_CHG_T
(PMT_RQST_ITM_ID)
/
-----------------------------------------------------------------------------
-- AP_PMT_RQST_ACCT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AP_PMT_RQST_ACCT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AP_PMT_RQST_ACCT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AP_PMT_RQST_ACCT_T
(
PMT_RQST_ACCT_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, PMT_RQST_ITM_ID NUMBER(10)
, FIN_COA_CD VARCHAR2(2) NOT NULL
, ACCOUNT_NBR VARCHAR2(7) NOT NULL
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, FIN_OBJECT_CD VARCHAR2(4) NOT NULL
, PROJECT_CD VARCHAR2(10)
, ORG_REFERENCE_ID VARCHAR2(8)
, ITM_ACCT_TOT_AMT NUMBER(19,2) NOT NULL
, ACLN_PCT NUMBER(35,20) NOT NULL
, DISENC_AMT NUMBER(19,2) NOT NULL
, FDOC_LINE_NBR NUMBER(7)
, CONSTRAINT AP_PMT_RQST_ACCT_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AP_PMT_RQST_ACCT_T
ADD CONSTRAINT AP_PMT_RQST_ACCT_TP1
PRIMARY KEY (PMT_RQST_ACCT_ID)
/
CREATE INDEX AP_PMT_RQST_ACCT_TI1
ON AP_PMT_RQST_ACCT_T
(PMT_RQST_ITM_ID)
/
-----------------------------------------------------------------------------
-- AP_PMT_RQST_ITM_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AP_PMT_RQST_ITM_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AP_PMT_RQST_ITM_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AP_PMT_RQST_ITM_T
(
PMT_RQST_ITM_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, PMT_RQST_ID NUMBER(9) NOT NULL
, ITM_LN_NBR NUMBER(3)
, ITM_TYP_CD VARCHAR2(4)
, ITM_DESC VARCHAR2(4000)
, ITM_CATLG_NBR VARCHAR2(30)
, ITM_AUX_PART_ID VARCHAR2(300)
, ITM_UOM_CD VARCHAR2(4)
, ITM_INV_QTY NUMBER(11,2)
, ITM_UNIT_PRC NUMBER(19,4)
, PO_ITM_UNIT_PRC NUMBER(19,4)
, CPTL_AST_TRN_TYP_CD VARCHAR2(4)
, ITM_CPTL_AST_NTE_TXT VARCHAR2(800)
, ITM_ASND_TO_TRADE_IN_IND VARCHAR2(1)
, ITM_OSTND_INV_QTY NUMBER(11,2)
, ITM_OSTND_INV_AMT NUMBER(19,2)
, ITM_TAX_AMT NUMBER(19,4)
, ITM_EXTND_PRC NUMBER(19,2)
, OLE_ITM_OSTND_INV_PRTS NUMBER(11,2)
, OLE_ITM_INV_PRTS NUMBER(11,2)
, OLE_DISCNT NUMBER(19,4)
, OLE_DISCNT_TYP VARCHAR2(1)
, OLE_FOR_DISCNT_TYP VARCHAR2(1)
, OLE_FOR_DISCNT NUMBER(19,4)
, OLE_FOR_LST_PRC NUMBER(19,4)
, OLE_FOR_DISCNT_AMT NUMBER(19,4)
, OLE_FOR_UNT_CST NUMBER(19,4)
, OLE_EXCHANGE_RT NUMBER(19,6)
, OLE_CON_CST NUMBER(19,4)
, OLE_PR_QTY VARCHAR2(1)
, OLE_PR_AMT VARCHAR2(1)
, OLE_PR_MAN VARCHAR2(1)
, OLE_FRMT_ID NUMBER(8)
, OLE_VNDR_IT_ID VARCHAR2(100)
, OLE_PO_ITM_ID NUMBER(10)
, OLE_LST_PRC NUMBER(19,4)
, OLE_DOCUMENT_UUID VARCHAR2(50)
, OLE_ADDL_CHRG_USD VARCHAR2(1) default 'N' NOT NULL
, OLE_REQ_RCPT_STATUS_ID NUMBER(10)
, CONSTRAINT AP_PMT_RQST_ITM_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AP_PMT_RQST_ITM_T
ADD CONSTRAINT AP_PMT_RQST_ITM_TP1
PRIMARY KEY (PMT_RQST_ITM_ID)
/
CREATE INDEX AP_PMT_RQST_ITM_TI1
ON AP_PMT_RQST_ITM_T
(PMT_RQST_ID)
/
-----------------------------------------------------------------------------
-- AP_PMT_RQST_ITM_USE_TAX_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AP_PMT_RQST_ITM_USE_TAX_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AP_PMT_RQST_ITM_USE_TAX_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AP_PMT_RQST_ITM_USE_TAX_T
(
PMT_RQST_ITM_USE_TAX_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, PMT_RQST_ITM_ID NUMBER(10)
, RATE_CD VARCHAR2(10) NOT NULL
, TAX_AMT NUMBER(19,4)
, FIN_COA_CD VARCHAR2(2) NOT NULL
, ACCOUNT_NBR VARCHAR2(7) NOT NULL
, FIN_OBJECT_CD VARCHAR2(4) NOT NULL
, CONSTRAINT AP_PMT_RQST_ITM_USE_TAX_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AP_PMT_RQST_ITM_USE_TAX_T
ADD CONSTRAINT AP_PMT_RQST_ITM_USE_TAX_TP1
PRIMARY KEY (PMT_RQST_ITM_USE_TAX_ID)
/
-----------------------------------------------------------------------------
-- AP_PMT_RQST_STAT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AP_PMT_RQST_STAT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AP_PMT_RQST_STAT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AP_PMT_RQST_STAT_T
(
PMT_RQST_STAT_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, PMT_RQST_STAT_DESC VARCHAR2(45) NOT NULL
, CONSTRAINT AP_PMT_RQST_STAT_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AP_PMT_RQST_STAT_T
ADD CONSTRAINT AP_PMT_RQST_STAT_TP1
PRIMARY KEY (PMT_RQST_STAT_CD)
/
-----------------------------------------------------------------------------
-- AP_PMT_RQST_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AP_PMT_RQST_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AP_PMT_RQST_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AP_PMT_RQST_T
(
PMT_RQST_ID NUMBER(9)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, PMT_RQST_STAT_CD VARCHAR2(4)
, FDOC_NBR VARCHAR2(14) NOT NULL
, PO_ID NUMBER(9) NOT NULL
, PO_ENCUM_FSCL_YR NUMBER(4) NOT NULL
, PO_CLSIF_TYP_DESC VARCHAR2(4)
, INV_RQST_ID NUMBER(9)
, INV_DT DATE NOT NULL
, INV_NBR VARCHAR2(25)
, VNDR_INV_AMT NUMBER(19,2)
, VNDR_PMT_TERMS_CD VARCHAR2(5)
, VNDR_SHP_PMT_TERM_CD VARCHAR2(4)
, VNDR_CUST_NBR VARCHAR2(30)
, PMT_RQST_PAY_DT DATE
, PMT_RQST_CST_SRC_CD VARCHAR2(4)
, PMT_RQST_CNCL_IND VARCHAR2(1)
, PMT_ATT_IND VARCHAR2(1)
, IMD_PMT_IND VARCHAR2(1)
, PMT_HLD_IND VARCHAR2(1)
, PMT_NTE_LN1_TXT VARCHAR2(90)
, PMT_NTE_LN2_TXT VARCHAR2(90)
, PMT_NTE_LN3_TXT VARCHAR2(90)
, PMT_SPCL_HANDLG_INSTRC_LN1_TXT VARCHAR2(90)
, PMT_SPCL_HANDLG_INSTRC_LN2_TXT VARCHAR2(90)
, PMT_SPCL_HANDLG_INSTRC_LN3_TXT VARCHAR2(90)
, PMT_PD_DT DATE
, PMT_RQST_ELCTRNC_INV_IND VARCHAR2(1)
, VNDR_HDR_GNRTD_ID NUMBER(10)
, VNDR_DTL_ASND_ID NUMBER(10)
, VNDR_NM VARCHAR2(45)
, VNDR_LN1_ADDR VARCHAR2(45)
, VNDR_LN2_ADDR VARCHAR2(45)
, VNDR_CTY_NM VARCHAR2(45)
, VNDR_ST_CD VARCHAR2(2)
, VNDR_PSTL_CD VARCHAR2(20)
, VNDR_CNTRY_CD VARCHAR2(2)
, PMT_EXTRT_DT DATE
, AP_PRCSR_ID VARCHAR2(40) NOT NULL
, AP_RQST_CNCL_ID VARCHAR2(40)
, AP_HLD_ID VARCHAR2(40)
, PRCS_CMP_CD VARCHAR2(2)
, AP_APRVL_DT DATE
, ORIG_VNDR_HDR_GNRTD_ID NUMBER(10)
, ORIG_VNDR_DTL_ASND_ID NUMBER(10)
, ALTRNT_VNDR_HDR_GNRTD_ID NUMBER(10)
, ALTRNT_VNDR_DTL_ASND_ID NUMBER(10)
, CONT_ACCT_IND VARCHAR2(1)
, AP_PUR_DOC_LNK_ID NUMBER(10)
, CLOSE_PO_IND VARCHAR2(1)
, REOPEN_PO_IND VARCHAR2(1)
, VNDR_ADDR_INTL_PROV_NM VARCHAR2(45)
, RCVNG_DOC_REQ_IND VARCHAR2(1)
, PMT_RQST_PSTV_APRVL_IND VARCHAR2(1)
, USE_TAX_IND VARCHAR2(1) default 'Y' NOT NULL
, BNK_CD VARCHAR2(4)
, TAX_CLSIF_CD VARCHAR2(50)
, FTX_PCT NUMBER(10,8)
, STX_PCT NUMBER(10,8)
, TAX_CNTRY_CD VARCHAR2(10)
, GRS_UP_IND VARCHAR2(1)
, TRTY_EXMPT_IND VARCHAR2(1)
, FRGN_SRC_IND VARCHAR2(1)
, SPCL_W4_INC_AMT NUMBER(19,2)
, USAID_DIEM_IND VARCHAR2(1)
, INC_TAX_EXMPT_CD_OTHR_IND VARCHAR2(1)
, NQI_CUST_TAX_ID VARCHAR2(50)
, VNDR_ATTN_NM VARCHAR2(45)
, OLE_VNDR_CURR_ID NUMBER(10)
, OLE_VNDR_FOR_CURR_INV_AMT NUMBER(19,2)
, OLE_INV_TYP_ID NUMBER(10)
, OLE_INV_SUB_TYP_ID NUMBER(10)
, OLE_PMT_MTHD_ID NUMBER(10)
, OLE_VNDR_PO_ID VARCHAR2(100)
, ACCT_DISTR_MTD_IND VARCHAR2(1) default 'P' NOT NULL
, OLE_PR_BY VARCHAR2(50)
, OLE_PRFRMA_IND VARCHAR2(1)
, CONSTRAINT AP_PMT_RQST_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AP_PMT_RQST_T
ADD CONSTRAINT AP_PMT_RQST_TP1
PRIMARY KEY (PMT_RQST_ID)
/
CREATE INDEX AP_PMT_RQST_TI1
ON AP_PMT_RQST_T
(PMT_RQST_STAT_CD)
/
CREATE INDEX AP_PMT_RQST_TI2
ON AP_PMT_RQST_T
(PO_ID)
/
CREATE INDEX AP_PMT_RQST_TI3
ON AP_PMT_RQST_T
(FDOC_NBR)
/
CREATE INDEX AP_PMT_RQST_TI4
ON AP_PMT_RQST_T
(AP_PUR_DOC_LNK_ID)
/
-----------------------------------------------------------------------------
-- AP_SUM_ACCT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AP_SUM_ACCT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AP_SUM_ACCT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AP_SUM_ACCT_T
(
SUM_ACCT_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, PMT_RQST_ID NUMBER(9)
, INV_RQST_ID NUMBER(9)
, FIN_COA_CD VARCHAR2(2) NOT NULL
, ACCOUNT_NBR VARCHAR2(7) NOT NULL
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, FIN_OBJECT_CD VARCHAR2(4) NOT NULL
, PROJECT_CD VARCHAR2(10)
, ORG_REFERENCE_ID VARCHAR2(8)
, ITM_ACCT_TOT_AMT NUMBER(19,2) NOT NULL
, CRDT_MEMO_ID NUMBER(9)
, LST_UPDT_TS DATE
, CONSTRAINT AP_SUM_ACCT_TI1 UNIQUE (PMT_RQST_ID, INV_RQST_ID, FIN_COA_CD, ACCOUNT_NBR, SUB_ACCT_NBR, FIN_SUB_OBJ_CD, FIN_OBJECT_CD, PROJECT_CD, ORG_REFERENCE_ID)
, CONSTRAINT AP_SUM_ACCT_TTC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AP_SUM_ACCT_T
ADD CONSTRAINT AP_SUM_ACCT_TP1
PRIMARY KEY (SUM_ACCT_ID)
/
-----------------------------------------------------------------------------
-- AR_APPLICATION_DOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AR_APPLICATION_DOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AR_APPLICATION_DOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AR_APPLICATION_DOC_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CONSTRAINT AR_APPLICATION_DOC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AR_APPLICATION_DOC_T
ADD CONSTRAINT AR_APPLICATION_DOC_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- AR_CRDT_MEMO_DOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AR_CRDT_MEMO_DOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AR_CRDT_MEMO_DOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AR_CRDT_MEMO_DOC_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_POST_YR NUMBER(4)
, FDOC_REF_INV_NBR VARCHAR2(14)
, CONSTRAINT AR_CRDT_MEMO_DOC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AR_CRDT_MEMO_DOC_T
ADD CONSTRAINT AR_CRDT_MEMO_DOC_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- AR_CRDT_MEMO_DTL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AR_CRDT_MEMO_DTL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AR_CRDT_MEMO_DTL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AR_CRDT_MEMO_DTL_T
(
FDOC_NBR VARCHAR2(14)
, REF_INV_ITM_NBR NUMBER(7)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CRDT_MEMO_ITM_QTY NUMBER(11,2)
, CRDT_MEMO_ITM_TAX_AMT NUMBER(19,2)
, CRDT_MEMO_ITM_TOT_AMT NUMBER(19,2)
, CONSTRAINT AR_CRDT_MEMO_DTL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AR_CRDT_MEMO_DTL_T
ADD CONSTRAINT AR_CRDT_MEMO_DTL_TP1
PRIMARY KEY (FDOC_NBR,REF_INV_ITM_NBR)
/
-----------------------------------------------------------------------------
-- AR_CSH_CTRL_DTL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AR_CSH_CTRL_DTL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AR_CSH_CTRL_DTL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AR_CSH_CTRL_DTL_T
(
FDOC_NBR VARCHAR2(14)
, FDOC_REF_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CUST_PMT_MEDIUM_ID VARCHAR2(30)
, FDOC_LINE_AMT NUMBER(19,2)
, CUST_PMT_DESC VARCHAR2(60)
, CUST_NBR VARCHAR2(9)
, CUST_PMT_DT DATE
, CONSTRAINT AR_CSH_CTRL_DTL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AR_CSH_CTRL_DTL_T
ADD CONSTRAINT AR_CSH_CTRL_DTL_TP1
PRIMARY KEY (FDOC_NBR,FDOC_REF_NBR)
/
CREATE INDEX AR_CSH_CTRL_DTL_TI2
ON AR_CSH_CTRL_DTL_T
(CUST_NBR)
/
CREATE INDEX AR_CSH_CTRL_DTL_TI3
ON AR_CSH_CTRL_DTL_T
(FDOC_REF_NBR)
/
-----------------------------------------------------------------------------
-- AR_CSH_CTRL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AR_CSH_CTRL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AR_CSH_CTRL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AR_CSH_CTRL_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_REF_NBR VARCHAR2(14)
, UNIV_FISCAL_YR NUMBER(4)
, UNIV_FISCAL_PRD_CD VARCHAR2(2)
, CUST_PMT_MEDIUM_CD VARCHAR2(2)
, AR_CSHCTRL_TOT_AMT NUMBER(19,2)
, BNK_CD VARCHAR2(4)
, CONSTRAINT AR_CSH_CTRL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AR_CSH_CTRL_T
ADD CONSTRAINT AR_CSH_CTRL_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- AR_CUST_ADDR_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AR_CUST_ADDR_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AR_CUST_ADDR_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AR_CUST_ADDR_T
(
CUST_NBR VARCHAR2(9)
, CUST_ADDR_ID NUMBER(7)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CUST_ADDR_NM VARCHAR2(40)
, CUST_LINE_1_ADDR VARCHAR2(30)
, CUST_LINE_2_ADDR VARCHAR2(30)
, CUST_CITY_NM VARCHAR2(25)
, CUST_STATE_CD VARCHAR2(2)
, CUST_ZIP_CD VARCHAR2(20)
, CUST_CNTRY_CD VARCHAR2(2)
, CUST_ADDR_INTL_PROV_NM VARCHAR2(45)
, CUST_INTL_MAIL_CD VARCHAR2(20)
, CUST_EMAIL_ADDR VARCHAR2(60)
, CUST_ADDR_TYPE_CD VARCHAR2(2)
, CUST_ADDR_END_DT DATE
, CONSTRAINT AR_CUST_ADDR_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AR_CUST_ADDR_T
ADD CONSTRAINT AR_CUST_ADDR_TP1
PRIMARY KEY (CUST_NBR,CUST_ADDR_ID)
/
-----------------------------------------------------------------------------
-- AR_CUST_ADDR_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AR_CUST_ADDR_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AR_CUST_ADDR_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AR_CUST_ADDR_TYP_T
(
CUST_ADDR_TYPE_CD VARCHAR2(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CUST_ADDR_TYP_DESC VARCHAR2(30)
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT AR_CUST_ADDR_TYP_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AR_CUST_ADDR_TYP_T
ADD CONSTRAINT AR_CUST_ADDR_TYP_TP1
PRIMARY KEY (CUST_ADDR_TYPE_CD)
/
-----------------------------------------------------------------------------
-- AR_CUST_BILLING_STMT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AR_CUST_BILLING_STMT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AR_CUST_BILLING_STMT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AR_CUST_BILLING_STMT_T
(
CUST_NBR VARCHAR2(9)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, PREV_BILLED_AMT NUMBER(19,2)
, REPORTED_DT DATE
, CONSTRAINT AR_CUST_BILLING_STMT_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AR_CUST_BILLING_STMT_T
ADD CONSTRAINT AR_CUST_BILLING_STMT_TP1
PRIMARY KEY (CUST_NBR)
/
-----------------------------------------------------------------------------
-- AR_CUST_PRCS_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AR_CUST_PRCS_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AR_CUST_PRCS_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AR_CUST_PRCS_TYP_T
(
CUST_SPCL_PRCS_CD VARCHAR2(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CUST_SPCLPRCS_DESC VARCHAR2(40)
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT AR_CUST_PRCS_TYP_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AR_CUST_PRCS_TYP_T
ADD CONSTRAINT AR_CUST_PRCS_TYP_TP1
PRIMARY KEY (CUST_SPCL_PRCS_CD)
/
-----------------------------------------------------------------------------
-- AR_CUST_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AR_CUST_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AR_CUST_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AR_CUST_T
(
CUST_NBR VARCHAR2(9)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CUST_NM VARCHAR2(60)
, CUST_PARENT_CO_NBR VARCHAR2(9)
, CUST_TYP_CD VARCHAR2(2)
, CUST_ADDR_CHG_DT DATE
, CUST_REC_ADD_DT DATE
, CUST_LST_ACTV_DT DATE
, CUST_ACTIVE_CD VARCHAR2(1)
, CUST_PHONE_NBR VARCHAR2(20)
, CUST_800_PHONE_NBR VARCHAR2(20)
, CUST_CNTCT_NM VARCHAR2(40)
, CUST_CNTCT_PHN_NBR VARCHAR2(20)
, CUST_FAX_NBR VARCHAR2(20)
, CUST_BIRTH_DT DATE
, CUST_TAX_EXMPT_IND VARCHAR2(1)
, CUST_CRDT_LMT_AMT NUMBER(19,2)
, CUST_CRDT_APRV_NM VARCHAR2(40)
, CUST_EMAIL_ADDR VARCHAR2(60)
, CUST_TAX_TYP_CD VARCHAR2(4)
, CUST_TAX_NBR VARCHAR2(255)
, CONSTRAINT AR_CUST_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AR_CUST_T
ADD CONSTRAINT AR_CUST_TP1
PRIMARY KEY (CUST_NBR)
/
-----------------------------------------------------------------------------
-- AR_CUST_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AR_CUST_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AR_CUST_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AR_CUST_TYP_T
(
CUST_TYP_CD VARCHAR2(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CUST_TYP_DESC VARCHAR2(40)
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT AR_CUST_TYP_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AR_CUST_TYP_T
ADD CONSTRAINT AR_CUST_TYP_TP1
PRIMARY KEY (CUST_TYP_CD)
/
-----------------------------------------------------------------------------
-- AR_DOC_HDR_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AR_DOC_HDR_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AR_DOC_HDR_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AR_DOC_HDR_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CUST_NBR VARCHAR2(9)
, PRCS_FIN_COA_CD VARCHAR2(2)
, PRCS_ORG_CD VARCHAR2(4)
, AR_ENTRY_DT DATE
, FDOC_EXPLAIN_TXT VARCHAR2(400)
, CONSTRAINT AR_DOC_HDR_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AR_DOC_HDR_T
ADD CONSTRAINT AR_DOC_HDR_TP1
PRIMARY KEY (FDOC_NBR)
/
CREATE INDEX AR_DOC_HDR_TI2
ON AR_DOC_HDR_T
(CUST_NBR)
/
-----------------------------------------------------------------------------
-- AR_DOC_RCURRNC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AR_DOC_RCURRNC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AR_DOC_RCURRNC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AR_DOC_RCURRNC_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_REF_NBR VARCHAR2(14)
, CUST_NBR VARCHAR2(9)
, DOC_RCURRNC_BEG_DT DATE
, DOC_RCURRNC_END_DT DATE
, DOC_TOT_RCURRNC_NBR NUMBER(7)
, DOC_RCURRNC_INTRV_CD VARCHAR2(1)
, DOC_INITR_USR_ID VARCHAR2(40)
, DOC_LST_CRTE_DT DATE
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT AR_DOC_RCURRNC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AR_DOC_RCURRNC_T
ADD CONSTRAINT AR_DOC_RCURRNC_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- AR_INV_DOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AR_INV_DOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AR_INV_DOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AR_INV_DOC_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, UNIV_FISCAL_YR NUMBER(4)
, UNIV_FISCAL_PRD_CD VARCHAR2(2)
, AR_INV_HDR_TXT VARCHAR2(120)
, AR_INV_ATTN_LN_TXT VARCHAR2(80)
, AR_INV_DUE_DT DATE
, AR_BILLING_DT DATE
, AR_INV_TERMS_TXT VARCHAR2(40)
, ORG_INV_NBR VARCHAR2(9)
, CUST_PO_NBR VARCHAR2(25)
, AR_PRN_INV_IND VARCHAR2(1)
, CUST_PO_DT DATE
, AR_BILL_BY_COA_CD VARCHAR2(2)
, AR_BILL_BY_ORG_CD VARCHAR2(4)
, CUST_SHIP_ADDR_ID NUMBER(7)
, CUST_BILL_ADDR_ID NUMBER(7)
, CUST_SPCL_PRCS_CD VARCHAR2(2)
, CUST_REC_ATT_IND CHAR(1)
, AR_OPEN_INV_IND VARCHAR2(1)
, PMT_FIN_COA_CD VARCHAR2(2)
, PMT_ACCT_NBR VARCHAR2(7)
, PMT_SUB_ACCT_NBR VARCHAR2(5)
, PMT_FIN_OBJ_CD VARCHAR2(4)
, PMT_FIN_SUB_OBJ_CD VARCHAR2(3)
, PMT_PROJECT_CD VARCHAR2(10)
, PMT_ORG_REF_ID VARCHAR2(8)
, AR_PRNT_DT DATE
, AR_INV_CLOSE_DT DATE
, CUST_NM VARCHAR2(60)
, BILL_ADDR_NM VARCHAR2(40)
, BILL_LINE_1_ADDR VARCHAR2(30)
, BILL_LINE_2_ADDR VARCHAR2(30)
, BILL_CITY_NM VARCHAR2(25)
, BILL_STATE_CD VARCHAR2(2)
, BILL_ZIP_CD VARCHAR2(20)
, BILL_CNTRY_CD VARCHAR2(2)
, BILL_ADDR_INTL_PROV_NM VARCHAR2(45)
, BILL_INTL_MAIL_CD VARCHAR2(20)
, BILL_EMAIL_ADDR VARCHAR2(60)
, BILL_ADDR_TYPE_CD VARCHAR2(2)
, SHIP_ADDR_NM VARCHAR2(40)
, SHIP_LINE_1_ADDR VARCHAR2(30)
, SHIP_LINE_2_ADDR VARCHAR2(30)
, SHIP_CITY_NM VARCHAR2(25)
, SHIP_STATE_CD VARCHAR2(2)
, SHIP_ZIP_CD VARCHAR2(20)
, SHIP_CNTRY_CD VARCHAR2(2)
, SHIP_ADDR_INTL_PROV_NM VARCHAR2(45)
, SHIP_INTL_MAIL_CD VARCHAR2(20)
, SHIP_EMAIL_ADDR VARCHAR2(60)
, SHIP_ADDR_TYPE_CD VARCHAR2(2)
, NXT_INV_ITEM_NBR NUMBER(7)
, RECURRED_INV_IND VARCHAR2(1)
, REPORTED_DT DATE
, CONSTRAINT AR_INV_DOC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AR_INV_DOC_T
ADD CONSTRAINT AR_INV_DOC_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- AR_INV_DTL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AR_INV_DTL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AR_INV_DTL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AR_INV_DTL_T
(
FDOC_NBR VARCHAR2(14)
, AR_INV_ITM_NBR NUMBER(7)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, SUB_ACCT_NBR VARCHAR2(5)
, FDOC_POST_YR NUMBER(4)
, FIN_OBJECT_CD VARCHAR2(4)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, PROJECT_CD VARCHAR2(10)
, ORG_REFERENCE_ID VARCHAR2(8)
, FIN_AR_OBJ_CD VARCHAR2(4)
, FIN_AR_SUB_OBJ_CD VARCHAR2(3)
, AR_INV_ITM_QTY NUMBER(11,2)
, AR_INV_ITM_UOM_CD VARCHAR2(2)
, AR_INVITM_UNIT_PRC NUMBER(19,4)
, AR_INV_ITM_TOT_AMT NUMBER(19,2)
, AR_INV_ITM_SRVC_DT DATE
, AR_INV_ITM_CD VARCHAR2(6)
, AR_INV_ITM_DESC VARCHAR2(400)
, FDOC_OVERRIDE_CD VARCHAR2(100)
, AR_INV_ITM_TAX_AMT NUMBER(19,2)
, AR_INV_ITM_TXBL_IND VARCHAR2(1)
, AR_INV_ITM_DSCT_LN_NBR NUMBER(7)
, CONSTRAINT AR_INV_DTL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AR_INV_DTL_T
ADD CONSTRAINT AR_INV_DTL_TP1
PRIMARY KEY (FDOC_NBR,AR_INV_ITM_NBR)
/
-----------------------------------------------------------------------------
-- AR_INV_ITM_CODE_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AR_INV_ITM_CODE_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AR_INV_ITM_CODE_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AR_INV_ITM_CODE_T
(
FIN_COA_CD VARCHAR2(2)
, ORG_CD VARCHAR2(4)
, AR_INV_ITM_CD VARCHAR2(6)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, AR_INV_ITM_DESC VARCHAR2(40)
, AR_RLTD_STOCK_NBR VARCHAR2(10)
, INV_FIN_COA_CD VARCHAR2(2)
, INV_ACCT_NBR VARCHAR2(7)
, INV_SUB_ACCT_NBR VARCHAR2(5)
, INV_FIN_OBJ_CD VARCHAR2(4)
, INV_FIN_SUB_OBJ_CD VARCHAR2(3)
, INV_PROJECT_CD VARCHAR2(10)
, INV_ORG_REF_ID VARCHAR2(8)
, AR_ITM_DFLT_PRC NUMBER(19,2)
, AR_DFLT_UOM_CD VARCHAR2(2)
, AR_ITM_DFLT_QTY NUMBER(11,2)
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, AR_INV_ITM_TXBL_IND VARCHAR2(1)
, CONSTRAINT AR_INV_ITM_CODE_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AR_INV_ITM_CODE_T
ADD CONSTRAINT AR_INV_ITM_CODE_TP1
PRIMARY KEY (FIN_COA_CD,ORG_CD,AR_INV_ITM_CD)
/
-----------------------------------------------------------------------------
-- AR_INV_PD_APLD_MT
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AR_INV_PD_APLD_MT';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AR_INV_PD_APLD_MT CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AR_INV_PD_APLD_MT
(
FDOC_NBR VARCHAR2(14)
, AR_PD_APLD_ITM_NBR NUMBER(7)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_REF_INV_NBR VARCHAR2(14)
, AR_INV_ITM_NBR NUMBER(7)
, UNIV_FISCAL_YR NUMBER(4)
, UNIV_FISCAL_PRD_CD VARCHAR2(2)
, AR_INV_ITMAPLD_AMT NUMBER(19,2)
, CONSTRAINT AR_INV_PD_APLD_MTC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AR_INV_PD_APLD_MT
ADD CONSTRAINT AR_INV_PD_APLD_MTP1
PRIMARY KEY (FDOC_NBR,AR_PD_APLD_ITM_NBR)
/
-----------------------------------------------------------------------------
-- AR_INV_PD_APLD_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AR_INV_PD_APLD_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AR_INV_PD_APLD_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AR_INV_PD_APLD_T
(
FDOC_NBR VARCHAR2(14)
, AR_PD_APLD_ITM_NBR NUMBER(7)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_REF_INV_NBR VARCHAR2(14)
, AR_INV_ITM_NBR NUMBER(7)
, UNIV_FISCAL_YR NUMBER(4)
, UNIV_FISCAL_PRD_CD VARCHAR2(2)
, AR_INV_ITMAPLD_AMT NUMBER(19,2)
, CONSTRAINT AR_INV_PD_APLD_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AR_INV_PD_APLD_T
ADD CONSTRAINT AR_INV_PD_APLD_TP1
PRIMARY KEY (FDOC_NBR,AR_PD_APLD_ITM_NBR)
/
CREATE INDEX AR_INV_PD_APLD_TI2
ON AR_INV_PD_APLD_T
(FDOC_REF_INV_NBR, AR_INV_ITM_NBR)
/
-----------------------------------------------------------------------------
-- AR_INV_RCURRNC_DTL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AR_INV_RCURRNC_DTL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AR_INV_RCURRNC_DTL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AR_INV_RCURRNC_DTL_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_REF_DOC_NBR VARCHAR2(14)
, CUST_NBR VARCHAR2(9)
, DOC_RCURRNC_BEG_DT DATE
, DOC_RCURRNC_END_DT DATE
, DOC_TOT_RCURRNC_NBR NUMBER(7)
, DOC_RCURRNC_INTRV_CD VARCHAR2(1)
, DOC_INITR_USR_ID VARCHAR2(40)
, ROW_ACTV_IND VARCHAR2(1)
, CONSTRAINT AR_INV_RCURRNC_DTL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AR_INV_RCURRNC_DTL_T
ADD CONSTRAINT AR_INV_RCURRNC_DTL_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- AR_LOCKBOX_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AR_LOCKBOX_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AR_LOCKBOX_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AR_LOCKBOX_T
(
AR_INV_SEQ_NBR NUMBER(12)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, AR_LOCKBOX_NBR VARCHAR2(10)
, CUST_NBR VARCHAR2(9)
, FDOC_REF_INV_NBR VARCHAR2(14)
, AR_BILLING_DT DATE
, AR_INV_TOT_AMT NUMBER(19,2)
, AR_INV_PD_APLD_AMT NUMBER(19,2)
, AR_SCAN_INV_DT DATE
, CUST_PMT_MEDIUM_CD VARCHAR2(2)
, AR_PRCS_INV_DT DATE
, AR_BATCH_SEQ_NBR NUMBER(5)
, BNK_CD VARCHAR2(4)
, CONSTRAINT AR_LOCKBOX_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AR_LOCKBOX_T
ADD CONSTRAINT AR_LOCKBOX_TP1
PRIMARY KEY (AR_INV_SEQ_NBR)
/
-----------------------------------------------------------------------------
-- AR_NON_APLD_DIST_MT
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AR_NON_APLD_DIST_MT';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AR_NON_APLD_DIST_MT CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AR_NON_APLD_DIST_MT
(
FDOC_NBR VARCHAR2(14)
, AR_PD_APLD_ITM_NBR NUMBER(7)
, FDOC_REF_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, UNIV_FISCAL_YR NUMBER(4)
, UNIV_FISCAL_PRD_CD VARCHAR2(2)
, FDOC_LINE_AMT NUMBER(19,2)
, CONSTRAINT AR_NON_APLD_DIST_MTC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AR_NON_APLD_DIST_MT
ADD CONSTRAINT AR_NON_APLD_DIST_MTP1
PRIMARY KEY (FDOC_NBR,AR_PD_APLD_ITM_NBR,FDOC_REF_NBR)
/
-----------------------------------------------------------------------------
-- AR_NON_APLD_DIST_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AR_NON_APLD_DIST_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AR_NON_APLD_DIST_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AR_NON_APLD_DIST_T
(
FDOC_NBR VARCHAR2(14)
, AR_PD_APLD_ITM_NBR NUMBER(7)
, FDOC_REF_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, UNIV_FISCAL_YR NUMBER(4)
, UNIV_FISCAL_PRD_CD VARCHAR2(2)
, FDOC_LINE_AMT NUMBER(19,2)
, CONSTRAINT AR_NON_APLD_DIST_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AR_NON_APLD_DIST_T
ADD CONSTRAINT AR_NON_APLD_DIST_TP1
PRIMARY KEY (FDOC_NBR,AR_PD_APLD_ITM_NBR,FDOC_REF_NBR)
/
-----------------------------------------------------------------------------
-- AR_NON_APLD_HLDG_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AR_NON_APLD_HLDG_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AR_NON_APLD_HLDG_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AR_NON_APLD_HLDG_T
(
FDOC_REF_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_LINE_AMT NUMBER(19,2)
, CUST_NBR VARCHAR2(9)
, CONSTRAINT AR_NON_APLD_HLDG_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AR_NON_APLD_HLDG_T
ADD CONSTRAINT AR_NON_APLD_HLDG_TP1
PRIMARY KEY (FDOC_REF_NBR)
/
CREATE INDEX AR_NON_APLD_HLDG_TI2
ON AR_NON_APLD_HLDG_T
(CUST_NBR)
/
-----------------------------------------------------------------------------
-- AR_NON_INV_DIST_MT
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AR_NON_INV_DIST_MT';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AR_NON_INV_DIST_MT CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AR_NON_INV_DIST_MT
(
FDOC_NBR VARCHAR2(14)
, FDOC_LINE_NBR NUMBER(7)
, FDOC_REF_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_LINE_AMT NUMBER(19,2)
, CONSTRAINT AR_NON_INV_DIST_MTC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AR_NON_INV_DIST_MT
ADD CONSTRAINT AR_NON_INV_DIST_MTP1
PRIMARY KEY (FDOC_NBR,FDOC_LINE_NBR,FDOC_REF_NBR)
/
-----------------------------------------------------------------------------
-- AR_NON_INV_DIST_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AR_NON_INV_DIST_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AR_NON_INV_DIST_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AR_NON_INV_DIST_T
(
FDOC_NBR VARCHAR2(14)
, FDOC_LINE_NBR NUMBER(7)
, FDOC_REF_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_LINE_AMT NUMBER(19,2)
, CONSTRAINT AR_NON_INV_DIST_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AR_NON_INV_DIST_T
ADD CONSTRAINT AR_NON_INV_DIST_TP1
PRIMARY KEY (FDOC_NBR,FDOC_LINE_NBR,FDOC_REF_NBR)
/
-----------------------------------------------------------------------------
-- AR_NON_INV_MT
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AR_NON_INV_MT';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AR_NON_INV_MT CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AR_NON_INV_MT
(
FDOC_NBR VARCHAR2(14)
, FDOC_LINE_NBR NUMBER(7)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_POST_YR NUMBER(4)
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_OBJECT_CD VARCHAR2(4)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, PROJECT_CD VARCHAR2(10)
, FDOC_LINE_AMT NUMBER(19,2)
, FDOC_OVERRIDE_CD VARCHAR2(100)
, CONSTRAINT AR_NON_INV_MTC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AR_NON_INV_MT
ADD CONSTRAINT AR_NON_INV_MTP1
PRIMARY KEY (FDOC_NBR,FDOC_LINE_NBR)
/
-----------------------------------------------------------------------------
-- AR_NON_INV_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AR_NON_INV_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AR_NON_INV_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AR_NON_INV_T
(
FDOC_NBR VARCHAR2(14)
, FDOC_LINE_NBR NUMBER(7)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_POST_YR NUMBER(4)
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_OBJECT_CD VARCHAR2(4)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, PROJECT_CD VARCHAR2(10)
, FDOC_LINE_AMT NUMBER(19,2)
, FDOC_OVERRIDE_CD VARCHAR2(100)
, CONSTRAINT AR_NON_INV_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AR_NON_INV_T
ADD CONSTRAINT AR_NON_INV_TP1
PRIMARY KEY (FDOC_NBR,FDOC_LINE_NBR)
/
-----------------------------------------------------------------------------
-- AR_OPEN_INV_DTL_MT
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AR_OPEN_INV_DTL_MT';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AR_OPEN_INV_DTL_MT CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AR_OPEN_INV_DTL_MT
(
SESID VARCHAR2(36)
, FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_TYP_CD VARCHAR2(8)
, AR_INV_ITM_NBR NUMBER(7)
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, AR_BILL_BY_COA_CD VARCHAR2(2)
, AR_BILL_BY_ORG_CD VARCHAR2(4)
, AR_BILLING_DT DATE
, AR_ENTRY_DT DATE
, AR_INV_DUE_DT DATE
, AR_INV_DESC VARCHAR2(40)
, AR_WRITEOFF_IND VARCHAR2(1)
, CUST_NBR VARCHAR2(9)
, PRCS_FIN_COA_CD VARCHAR2(2)
, PRCS_ORG_CD VARCHAR2(4)
, CUST_NM VARCHAR2(60)
, AR_INV_ITM_TOT_AMT NUMBER(19,2)
, AR_INV_ITMAPLD_AMT NUMBER(19,2)
, CONSTRAINT AR_OPEN_INV_DTL_MTC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AR_OPEN_INV_DTL_MT
ADD CONSTRAINT AR_OPEN_INV_DTL_MTP1
PRIMARY KEY (SESID,FDOC_NBR)
/
-----------------------------------------------------------------------------
-- AR_ORG_ACCTGDFLT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AR_ORG_ACCTGDFLT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AR_ORG_ACCTGDFLT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AR_ORG_ACCTGDFLT_T
(
UNIV_FISCAL_YR NUMBER(4)
, FIN_COA_CD VARCHAR2(2)
, ORG_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ORG_LT_CHRG_OBJ_CD VARCHAR2(4)
, INV_ACCT_NBR VARCHAR2(7)
, INV_SUB_ACCT_NBR VARCHAR2(5)
, INV_FIN_OBJ_CD VARCHAR2(4)
, INV_FIN_SUB_OBJ_CD VARCHAR2(3)
, INV_PROJECT_CD VARCHAR2(10)
, INV_ORG_REF_ID VARCHAR2(8)
, PMT_ACCT_NBR VARCHAR2(7)
, PMT_SUB_ACCT_NBR VARCHAR2(5)
, PMT_FIN_OBJ_CD VARCHAR2(4)
, PMT_FIN_SUB_OBJ_CD VARCHAR2(3)
, PMT_PROJECT_CD VARCHAR2(10)
, PMT_ORG_REF_ID VARCHAR2(8)
, WRITEOFF_ACCT_NBR VARCHAR2(7)
, WRITEOFF_SUB_ACCT_NBR VARCHAR2(5)
, WRITEOFF_FIN_OBJ_CD VARCHAR2(4)
, WRITEOFF_FIN_SUB_OBJ_CD VARCHAR2(3)
, WRITEOFF_PROJECT_CD VARCHAR2(10)
, WRITEOFF_ORG_REF_ID VARCHAR2(8)
, PMT_FIN_COA_CD VARCHAR2(2)
, INV_FIN_COA_CD VARCHAR2(2)
, WRITEOFF_FIN_COA_CD VARCHAR2(2)
, CONSTRAINT AR_ORG_ACCTGDFLT_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AR_ORG_ACCTGDFLT_T
ADD CONSTRAINT AR_ORG_ACCTGDFLT_TP1
PRIMARY KEY (UNIV_FISCAL_YR,FIN_COA_CD,ORG_CD)
/
-----------------------------------------------------------------------------
-- AR_ORG_OPTION_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AR_ORG_OPTION_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AR_ORG_OPTION_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AR_ORG_OPTION_T
(
FIN_COA_CD VARCHAR2(2)
, ORG_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, PRCS_FIN_COA_CD VARCHAR2(2)
, PRCS_ORG_CD VARCHAR2(4)
, AR_PRN_INV_IND VARCHAR2(1)
, ORG_PMT_TERMS_TXT VARCHAR2(40)
, ORG_MSG_TXT VARCHAR2(80)
, ORG_REMIT_ADDR_NM VARCHAR2(40)
, ORG_REMIT_LN1_ADDR VARCHAR2(30)
, ORG_REMIT_LN2_ADDR VARCHAR2(30)
, ORG_REMIT_CITY_NM VARCHAR2(25)
, ORG_REMIT_ST_CD VARCHAR2(2)
, ORG_REMIT_ZIP_CD VARCHAR2(20)
, ORG_PHONE_NBR VARCHAR2(13)
, ORG_800_PHONE_NBR VARCHAR2(13)
, ORG_FAX_NBR VARCHAR2(13)
, UNIV_NM VARCHAR2(40)
, ORG_CHCK_PAY_TO_NM VARCHAR2(40)
, ORG_POSTAL_ZIP_CD VARCHAR2(20)
, ORG_POSTAL_CNTRY_CD VARCHAR2(2)
, CONSTRAINT AR_ORG_OPTION_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AR_ORG_OPTION_T
ADD CONSTRAINT AR_ORG_OPTION_TP1
PRIMARY KEY (FIN_COA_CD,ORG_CD)
/
-----------------------------------------------------------------------------
-- AR_PMT_MEDIUM_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AR_PMT_MEDIUM_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AR_PMT_MEDIUM_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AR_PMT_MEDIUM_T
(
CUST_PMT_MEDIUM_CD VARCHAR2(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CUST_PMT_MEDM_DESC VARCHAR2(40)
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT AR_PMT_MEDIUM_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AR_PMT_MEDIUM_T
ADD CONSTRAINT AR_PMT_MEDIUM_TP1
PRIMARY KEY (CUST_PMT_MEDIUM_CD)
/
-----------------------------------------------------------------------------
-- AR_PRN_INV_OPTN_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AR_PRN_INV_OPTN_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AR_PRN_INV_OPTN_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AR_PRN_INV_OPTN_T
(
AR_PRN_INV_IND VARCHAR2(1)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, AR_PRN_INV_DESC VARCHAR2(40)
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT AR_PRN_INV_OPTN_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AR_PRN_INV_OPTN_T
ADD CONSTRAINT AR_PRN_INV_OPTN_TP1
PRIMARY KEY (AR_PRN_INV_IND)
/
-----------------------------------------------------------------------------
-- AR_SYS_INFO_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AR_SYS_INFO_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AR_SYS_INFO_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AR_SYS_INFO_T
(
UNIV_FISCAL_YR NUMBER(4)
, PRCS_FIN_COA_CD VARCHAR2(2)
, PRCS_ORG_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, UNIV_FEIN_NBR VARCHAR2(9)
, REFUND_FIN_OBJ_CD VARCHAR2(4)
, UNIV_CLR_COA_CD VARCHAR2(2)
, UNIV_CLR_ACCT_NBR VARCHAR2(7)
, UNIV_CLR_SUBAC_NBR VARCHAR2(5)
, UNIV_CLR_OBJECT_CD VARCHAR2(4)
, UNIV_CLR_SUBOBJ_CD VARCHAR2(3)
, PMT_CLR_FIN_OBJ_CD VARCHAR2(4)
, AR_LOCKBOX_NBR VARCHAR2(10)
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, ORG_REMIT_ADDR_NM VARCHAR2(40)
, ORG_REMIT_LN1_ADDR VARCHAR2(30)
, ORG_REMIT_LN2_ADDR VARCHAR2(30)
, ORG_REMIT_CITY_NM VARCHAR2(25)
, ORG_REMIT_ST_CD VARCHAR2(2)
, ORG_REMIT_ZIP_CD VARCHAR2(20)
, ORG_CHCK_PAY_TO_NM VARCHAR2(40)
, FDOC_INITIATOR_ID VARCHAR2(40)
, CONSTRAINT AR_SYS_INFO_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AR_SYS_INFO_T
ADD CONSTRAINT AR_SYS_INFO_TP1
PRIMARY KEY (UNIV_FISCAL_YR,PRCS_FIN_COA_CD,PRCS_ORG_CD)
/
-----------------------------------------------------------------------------
-- AR_WRITEOFF_DOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'AR_WRITEOFF_DOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE AR_WRITEOFF_DOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE AR_WRITEOFF_DOC_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_POST_YR NUMBER(4)
, UNIV_FISCAL_PRD_CD VARCHAR2(2)
, FDOC_REF_INV_NBR VARCHAR2(14)
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_OBJECT_CD VARCHAR2(4)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, PROJECT_CD VARCHAR2(10)
, ORG_REFERENCE_ID VARCHAR2(8)
, AR_INV_WRTOFF_AMT NUMBER(19,2) NOT NULL
, CONSTRAINT AR_WRITEOFF_DOC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE AR_WRITEOFF_DOC_T
ADD CONSTRAINT AR_WRITEOFF_DOC_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- BATCH_LOAD_DOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'BATCH_LOAD_DOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE BATCH_LOAD_DOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE BATCH_LOAD_DOC_T
(
OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_NBR VARCHAR2(14) NOT NULL
)
/
-----------------------------------------------------------------------------
-- CA_A21_ICR_ACCT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_A21_ICR_ACCT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_A21_ICR_ACCT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_A21_ICR_ACCT_T
(
CA_A21_ICR_ACCT_GNRTD_ID NUMBER(10) default 0
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FIN_COA_CD VARCHAR2(2) NOT NULL
, ACCOUNT_NBR VARCHAR2(7) NOT NULL
, SUB_ACCT_NBR VARCHAR2(5) NOT NULL
, ICR_FIN_COA_CD VARCHAR2(2) NOT NULL
, ICR_FIN_ACCT_NBR VARCHAR2(7)
, ACLN_PCT VARCHAR2(45)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
)
/
ALTER TABLE CA_A21_ICR_ACCT_T
ADD CONSTRAINT CA_A21_ICR_ACCT_TP1
PRIMARY KEY (CA_A21_ICR_ACCT_GNRTD_ID)
/
-----------------------------------------------------------------------------
-- CA_A21_SUB_ACCT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_A21_SUB_ACCT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_A21_SUB_ACCT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_A21_SUB_ACCT_T
(
FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, SUB_ACCT_NBR VARCHAR2(5)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, SUB_ACCT_TYP_CD VARCHAR2(2) default 'EX'
, ICR_TYP_CD VARCHAR2(2)
, FIN_SERIES_ID VARCHAR2(3)
, ICR_FIN_COA_CD VARCHAR2(2)
, ICR_ACCOUNT_NBR VARCHAR2(7)
, OFF_CMP_CD VARCHAR2(1)
, CST_SHR_COA_CD VARCHAR2(2)
, CST_SHRSRCACCT_NBR VARCHAR2(7)
, CST_SRCSUBACCT_NBR VARCHAR2(5)
, CONSTRAINT CA_A21_SUB_ACCT_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_A21_SUB_ACCT_T
ADD CONSTRAINT CA_A21_SUB_ACCT_TP1
PRIMARY KEY (FIN_COA_CD,ACCOUNT_NBR,SUB_ACCT_NBR)
/
-----------------------------------------------------------------------------
-- CA_ACCOUNT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_ACCOUNT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_ACCOUNT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_ACCOUNT_T
(
FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ACCOUNT_NM VARCHAR2(40)
, ACCT_FSC_OFC_UID VARCHAR2(40)
, ACCT_SPVSR_UNVL_ID VARCHAR2(40)
, ACCT_MGR_UNVL_ID VARCHAR2(40)
, ORG_CD VARCHAR2(4)
, ACCT_TYP_CD VARCHAR2(2)
, ACCT_PHYS_CMP_CD VARCHAR2(2)
, SUB_FUND_GRP_CD VARCHAR2(6)
, ACCT_FRNG_BNFT_CD VARCHAR2(1)
, FIN_HGH_ED_FUNC_CD VARCHAR2(4)
, ACCT_RSTRC_STAT_CD VARCHAR2(1)
, ACCT_RSTRC_STAT_DT DATE
, ACCT_CITY_NM VARCHAR2(25)
, ACCT_STATE_CD VARCHAR2(2)
, ACCT_STREET_ADDR VARCHAR2(30)
, ACCT_ZIP_CD VARCHAR2(20)
, RPTS_TO_FIN_COA_CD VARCHAR2(2)
, RPTS_TO_ACCT_NBR VARCHAR2(7)
, ACCT_CREATE_DT DATE
, ACCT_EFFECT_DT DATE
, ACCT_EXPIRATION_DT DATE
, CONT_FIN_COA_CD VARCHAR2(2)
, CONT_ACCOUNT_NBR VARCHAR2(7)
, ENDOW_FIN_COA_CD VARCHAR2(2)
, ENDOW_ACCOUNT_NBR VARCHAR2(7)
, CONTR_CTRL_FCOA_CD VARCHAR2(2)
, CONTR_CTRLACCT_NBR VARCHAR2(7)
, INCOME_FIN_COA_CD VARCHAR2(2)
, INCOME_ACCOUNT_NBR VARCHAR2(7)
, ACCT_ICR_TYP_CD VARCHAR2(2)
, AC_CSTM_ICREXCL_CD VARCHAR2(1)
, FIN_SERIES_ID VARCHAR2(3)
, ICR_FIN_COA_CD VARCHAR2(2)
, ICR_ACCOUNT_NBR VARCHAR2(7)
, ACCT_IN_FP_CD VARCHAR2(1)
, BDGT_REC_LVL_CD VARCHAR2(1)
, ACCT_SF_CD VARCHAR2(1) default 'N'
, ACCT_PND_SF_CD VARCHAR2(1)
, FIN_EXT_ENC_SF_CD VARCHAR2(1)
, FIN_INT_ENC_SF_CD VARCHAR2(1)
, FIN_PRE_ENC_SF_CD VARCHAR2(1)
, FIN_OBJ_PRSCTRL_CD VARCHAR2(1)
, CG_CFDA_NBR VARCHAR2(6)
, ACCT_OFF_CMP_IND VARCHAR2(1)
, ACCT_CLOSED_IND VARCHAR2(1)
, CG_ACCT_RESP_ID NUMBER(2)
, OLE_UNIV_ACCT_NBR VARCHAR2(100) NOT NULL
, LBR_BEN_RT_CAT_CD VARCHAR2(2) default '--'
, VNDR_HDR_GNRTD_ID NUMBER(10)
, VNDR_DTL_ASND_ID NUMBER(10)
, THRESHOLD_AMOUNT NUMBER(10)
, THRESHOLD_PERCENTAGE NUMBER(10)
, CONSTRAINT CA_ACCOUNT_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_ACCOUNT_T
ADD CONSTRAINT CA_ACCOUNT_TP1
PRIMARY KEY (FIN_COA_CD,ACCOUNT_NBR)
/
CREATE INDEX CA_ACCOUNT_TI10
ON CA_ACCOUNT_T
(ACCT_MGR_UNVL_ID)
/
CREATE INDEX CA_ACCOUNT_TI11
ON CA_ACCOUNT_T
(ACCT_SPVSR_UNVL_ID)
/
CREATE INDEX CA_ACCOUNT_TI2
ON CA_ACCOUNT_T
(ACCOUNT_NBR, FIN_COA_CD)
/
CREATE INDEX CA_ACCOUNT_TI3
ON CA_ACCOUNT_T
(ACCT_TYP_CD)
/
CREATE INDEX CA_ACCOUNT_TI4
ON CA_ACCOUNT_T
(FIN_HGH_ED_FUNC_CD)
/
CREATE INDEX CA_ACCOUNT_TI5
ON CA_ACCOUNT_T
(FIN_COA_CD, ORG_CD)
/
CREATE INDEX CA_ACCOUNT_TI6
ON CA_ACCOUNT_T
(ACCT_RSTRC_STAT_CD)
/
CREATE INDEX CA_ACCOUNT_TI7
ON CA_ACCOUNT_T
(SUB_FUND_GRP_CD)
/
CREATE INDEX CA_ACCOUNT_TI8
ON CA_ACCOUNT_T
(ACCT_FSC_OFC_UID)
/
CREATE INDEX CA_ACCOUNT_TI9
ON CA_ACCOUNT_T
(ACCT_PHYS_CMP_CD)
/
-----------------------------------------------------------------------------
-- CA_ACCOUNT_TYPE_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_ACCOUNT_TYPE_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_ACCOUNT_TYPE_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_ACCOUNT_TYPE_T
(
ACCT_TYP_CD VARCHAR2(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ACCT_TYP_NM VARCHAR2(40)
, ROW_ACTV_IND VARCHAR2(1) default 'Y' NOT NULL
, CONSTRAINT CA_ACCOUNT_TYPE_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_ACCOUNT_TYPE_T
ADD CONSTRAINT CA_ACCOUNT_TYPE_TP1
PRIMARY KEY (ACCT_TYP_CD)
/
-----------------------------------------------------------------------------
-- CA_ACCTG_CTGRY_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_ACCTG_CTGRY_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_ACCTG_CTGRY_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_ACCTG_CTGRY_T
(
ACCTG_CTGRY_CD VARCHAR2(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ACCTG_CTGRY_DESC VARCHAR2(40)
, ACCTG_CTGRY_SHRT_NM VARCHAR2(12)
, FIN_REPORT_SORT_CD VARCHAR2(2)
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT CA_ACCTG_CTGRY_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_ACCTG_CTGRY_T
ADD CONSTRAINT CA_ACCTG_CTGRY_TP1
PRIMARY KEY (ACCTG_CTGRY_CD)
/
-----------------------------------------------------------------------------
-- CA_ACCT_AUTODEF_ICR_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_ACCT_AUTODEF_ICR_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_ACCT_AUTODEF_ICR_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_ACCT_AUTODEF_ICR_T
(
CA_ICR_ACCT_GNRTD_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ACCT_DFLT_ID NUMBER(10)
, ICR_FIN_COA_CD VARCHAR2(2)
, ICR_FIN_ACCT_NBR VARCHAR2(7)
, ACLN_PCT VARCHAR2(45)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) default 'Y'
, CONSTRAINT CA_ACCT_AUTODEF_ICR_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_ACCT_AUTODEF_ICR_T
ADD CONSTRAINT CA_ACCT_AUTODEF_ICR_TP1
PRIMARY KEY (CA_ICR_ACCT_GNRTD_ID)
/
-----------------------------------------------------------------------------
-- CA_ACCT_AUTO_CREATE_DFLT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_ACCT_AUTO_CREATE_DFLT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_ACCT_AUTO_CREATE_DFLT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_ACCT_AUTO_CREATE_DFLT_T
(
KC_UNIT VARCHAR2(8)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FIN_COA_CD VARCHAR2(2)
, KC_UNIT_NAME VARCHAR2(40)
, ACCT_ZIP_CD VARCHAR2(20)
, ACCT_CITY_NM VARCHAR2(25)
, ACCT_STATE_CD VARCHAR2(2)
, ACCT_STREET_ADDR VARCHAR2(30)
, ACCT_OFF_CMP_IND VARCHAR2(1)
, ACCT_TYP_CD VARCHAR2(2)
, ACCT_PHYS_CMP_CD VARCHAR2(2)
, SUB_FUND_GRP_CD VARCHAR2(6)
, ACCT_FRNG_BNFT_CD VARCHAR2(1)
, RPTS_TO_FIN_COA_CD VARCHAR2(2)
, RPTS_TO_ACCT_NBR VARCHAR2(7)
, FIN_HGH_ED_FUNC_CD VARCHAR2(4)
, ACCT_FSC_OFC_UID VARCHAR2(40)
, ACCT_SPVSR_UNVL_ID VARCHAR2(40)
, ACCT_MGR_UNVL_ID VARCHAR2(40)
, ORG_CD VARCHAR2(4)
, CONT_FIN_COA_CD VARCHAR2(2)
, CONT_ACCOUNT_NBR VARCHAR2(7)
, INCOME_FIN_COA_CD VARCHAR2(2)
, INCOME_ACCOUNT_NBR VARCHAR2(7)
, BDGT_REC_LVL_CD VARCHAR2(1)
, ACCT_SF_CD VARCHAR2(1)
, ACCT_PND_SF_CD VARCHAR2(1)
, FIN_EXT_ENC_SF_CD VARCHAR2(1)
, FIN_INT_ENC_SF_CD VARCHAR2(1)
, FIN_PRE_ENC_SF_CD VARCHAR2(1)
, FIN_OBJ_PRSCTRL_CD VARCHAR2(1)
, ICR_FIN_COA_CD VARCHAR2(2)
, ICR_ACCOUNT_NBR VARCHAR2(7)
, CG_ACCT_RESP_ID NUMBER(2)
, ACCT_ICR_TYP_CD VARCHAR2(2)
, ACCT_EXPNS_GUIDE_TXT VARCHAR2(400)
, ACCT_INCM_GUIDE_TXT VARCHAR2(400)
, ACCT_PRPS_GUIDE_TXT VARCHAR2(400)
, ACCT_DESC_CMPS_CD VARCHAR2(2)
, ACCT_DESC_BLDG_CD VARCHAR2(10)
, CONTR_CTRL_FCOA_CD VARCHAR2(2)
, CONTR_CTRLACCT_NBR VARCHAR2(7)
, FIN_SERIES_ID VARCHAR2(3)
, ACCT_CLOSED_IND VARCHAR2(1)
)
/
ALTER TABLE CA_ACCT_AUTO_CREATE_DFLT_T
ADD CONSTRAINT CA_ACCT_AUTO_CREATE_DFLT_TP1
PRIMARY KEY (KC_UNIT)
/
-----------------------------------------------------------------------------
-- CA_ACCT_CHG_DOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_ACCT_CHG_DOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_ACCT_CHG_DOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_ACCT_CHG_DOC_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ACCT_FSC_OFC_UID VARCHAR2(40)
, ACCT_SPVSR_UNVL_ID VARCHAR2(40)
, ACCT_MGR_UNVL_ID VARCHAR2(40)
, FIN_COA_CD VARCHAR2(2)
, ORG_CD VARCHAR2(4)
, SUB_FUND_GRP_CD VARCHAR2(6)
, ACCT_CITY_NM VARCHAR2(25)
, ACCT_STATE_CD VARCHAR2(2)
, ACCT_STREET_ADDR VARCHAR2(30)
, ACCT_ZIP_CD VARCHAR2(20)
, ACCT_EXPIRATION_DT DATE
, CONT_FIN_COA_CD VARCHAR2(2)
, CONT_ACCOUNT_NBR VARCHAR2(7)
, INCOME_FIN_COA_CD VARCHAR2(2)
, INCOME_ACCOUNT_NBR VARCHAR2(7)
, CG_CFDA_NBR VARCHAR2(6)
, FIN_HGH_ED_FUNC_CD VARCHAR2(4)
, ACCT_SF_CD VARCHAR2(1)
, ACCT_PND_SF_CD VARCHAR2(1)
, ACCT_SRCH_CRTA_TXT VARCHAR2(400)
, LBR_BEN_RT_CAT_CD VARCHAR2(2)
, CONSTRAINT CA_ACCT_CHG_DOC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_ACCT_CHG_DOC_T
ADD CONSTRAINT CA_ACCT_CHG_DOC_TP1
PRIMARY KEY (FDOC_NBR)
/
CREATE INDEX CA_ACCT_CHG_DOC_TI2
ON CA_ACCT_CHG_DOC_T
(ACCT_FSC_OFC_UID)
/
CREATE INDEX CA_ACCT_CHG_DOC_TI3
ON CA_ACCT_CHG_DOC_T
(ACCT_MGR_UNVL_ID)
/
CREATE INDEX CA_ACCT_CHG_DOC_TI4
ON CA_ACCT_CHG_DOC_T
(ACCT_SPVSR_UNVL_ID)
/
-----------------------------------------------------------------------------
-- CA_ACCT_CHG_DTL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_ACCT_CHG_DTL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_ACCT_CHG_DTL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_ACCT_CHG_DTL_T
(
FDOC_NBR VARCHAR2(14)
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CONSTRAINT CA_ACCT_CHG_DTL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_ACCT_CHG_DTL_T
ADD CONSTRAINT CA_ACCT_CHG_DTL_TP1
PRIMARY KEY (FDOC_NBR,FIN_COA_CD,ACCOUNT_NBR)
/
CREATE INDEX CA_ACCT_CHG_DTL_TI2
ON CA_ACCT_CHG_DTL_T
(FIN_COA_CD, ACCOUNT_NBR)
/
CREATE INDEX CA_ACCT_CHG_DTL_TI3
ON CA_ACCT_CHG_DTL_T
(FDOC_NBR)
/
-----------------------------------------------------------------------------
-- CA_ACCT_DELEGATE_GBL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_ACCT_DELEGATE_GBL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_ACCT_DELEGATE_GBL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_ACCT_DELEGATE_GBL_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
)
/
ALTER TABLE CA_ACCT_DELEGATE_GBL_T
ADD CONSTRAINT CA_ACCT_DELEGATE_GBL_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- CA_ACCT_DELEGATE_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_ACCT_DELEGATE_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_ACCT_DELEGATE_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_ACCT_DELEGATE_T
(
FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, FDOC_TYP_CD VARCHAR2(64)
, ACCT_DLGT_UNVL_ID VARCHAR2(40)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_APRV_FROM_AMT NUMBER(19,2)
, ACCT_DLGT_PRMRT_CD VARCHAR2(1)
, ACCT_DLGT_ACTV_CD VARCHAR2(1)
, ACCT_DLGT_START_DT DATE
, FDOC_APRV_TO_AMT NUMBER(19,2)
, CONSTRAINT CA_ACCT_DELEGATE_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_ACCT_DELEGATE_T
ADD CONSTRAINT CA_ACCT_DELEGATE_TP1
PRIMARY KEY (FIN_COA_CD,ACCOUNT_NBR,FDOC_TYP_CD,ACCT_DLGT_UNVL_ID)
/
CREATE INDEX CA_ACCT_DELEGATE_TI2
ON CA_ACCT_DELEGATE_T
(ACCT_DLGT_UNVL_ID)
/
-----------------------------------------------------------------------------
-- CA_ACCT_DESC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_ACCT_DESC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_ACCT_DESC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_ACCT_DESC_T
(
FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CAMPUS_DESC VARCHAR2(40)
, ORG_DESC VARCHAR2(40)
, RC_DESC VARCHAR2(40)
, CAMPUS_CD VARCHAR2(2)
, BLDG_CD VARCHAR2(10)
, CONSTRAINT CA_ACCT_DESC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_ACCT_DESC_T
ADD CONSTRAINT CA_ACCT_DESC_TP1
PRIMARY KEY (FIN_COA_CD,ACCOUNT_NBR)
/
-----------------------------------------------------------------------------
-- CA_ACCT_GDLNPRPS_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_ACCT_GDLNPRPS_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_ACCT_GDLNPRPS_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_ACCT_GDLNPRPS_T
(
FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ACCT_EXP_GDLN_TXT VARCHAR2(400)
, ACCT_INC_GDLN_TXT VARCHAR2(400)
, ACCT_PURPOSE_TXT VARCHAR2(400)
, CONSTRAINT CA_ACCT_GDLNPRPS_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_ACCT_GDLNPRPS_T
ADD CONSTRAINT CA_ACCT_GDLNPRPS_TP1
PRIMARY KEY (FIN_COA_CD,ACCOUNT_NBR)
/
-----------------------------------------------------------------------------
-- CA_ACCT_SF_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_ACCT_SF_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_ACCT_SF_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_ACCT_SF_T
(
ACCT_SF_CD VARCHAR2(1)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ACCT_SF_NM VARCHAR2(40)
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT CA_ACCT_SF_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_ACCT_SF_T
ADD CONSTRAINT CA_ACCT_SF_TP1
PRIMARY KEY (ACCT_SF_CD)
/
-----------------------------------------------------------------------------
-- CA_AICPA_FUNC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_AICPA_FUNC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_AICPA_FUNC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_AICPA_FUNC_T
(
FIN_AICPA_FUNC_CD VARCHAR2(3)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FIN_AICPA_FUNC_NM VARCHAR2(40)
, ROW_ACTV_IND VARCHAR2(1) default 'Y' NOT NULL
, CONSTRAINT CA_AICPA_FUNC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_AICPA_FUNC_T
ADD CONSTRAINT CA_AICPA_FUNC_TP1
PRIMARY KEY (FIN_AICPA_FUNC_CD)
/
-----------------------------------------------------------------------------
-- CA_BALANCE_TYPE_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_BALANCE_TYPE_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_BALANCE_TYPE_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_BALANCE_TYPE_T
(
FIN_BALANCE_TYP_CD VARCHAR2(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FIN_BALANCE_TYP_NM VARCHAR2(40)
, FIN_BALTYP_SHRT_NM VARCHAR2(12)
, FIN_OFFST_GNRTN_CD VARCHAR2(1)
, FIN_BALTYP_ENC_CD VARCHAR2(1)
, ROW_ACTV_IND VARCHAR2(1) default 'Y' NOT NULL
, CONSTRAINT CA_BALANCE_TYPE_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_BALANCE_TYPE_T
ADD CONSTRAINT CA_BALANCE_TYPE_TP1
PRIMARY KEY (FIN_BALANCE_TYP_CD)
/
-----------------------------------------------------------------------------
-- CA_BDGT_AGGR_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_BDGT_AGGR_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_BDGT_AGGR_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_BDGT_AGGR_T
(
FOBJ_BDGT_AGGR_CD VARCHAR2(1)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, FIN_BDGT_AGGR_NM VARCHAR2(40)
, CONSTRAINT CA_BDGT_AGGR_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_BDGT_AGGR_T
ADD CONSTRAINT CA_BDGT_AGGR_TP1
PRIMARY KEY (FOBJ_BDGT_AGGR_CD)
/
-----------------------------------------------------------------------------
-- CA_BDGT_REC_LVL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_BDGT_REC_LVL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_BDGT_REC_LVL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_BDGT_REC_LVL_T
(
BDGT_REC_LVL_CD VARCHAR2(1)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, BDGT_REC_LVL_NM VARCHAR2(40)
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT CA_BDGT_REC_LVL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_BDGT_REC_LVL_T
ADD CONSTRAINT CA_BDGT_REC_LVL_TP1
PRIMARY KEY (BDGT_REC_LVL_CD)
/
-----------------------------------------------------------------------------
-- CA_CFDA_REF_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_CFDA_REF_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_CFDA_REF_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_CFDA_REF_T
(
CG_CFDA_NBR VARCHAR2(6)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CG_CFDA_PGM_TTL_NM VARCHAR2(300)
, CG_CFDA_MAINT_TYP_ID VARCHAR2(10)
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT CG_CFDA_REF_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_CFDA_REF_T
ADD CONSTRAINT CA_CFDA_REF_TP1
PRIMARY KEY (CG_CFDA_NBR)
/
-----------------------------------------------------------------------------
-- CA_CHART_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_CHART_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_CHART_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_CHART_T
(
FIN_COA_CD VARCHAR2(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FIN_COA_DESC VARCHAR2(40)
, FIN_COA_ACTIVE_CD VARCHAR2(1)
, FIN_CASH_OBJ_CD VARCHAR2(4)
, FIN_AP_OBJ_CD VARCHAR2(4)
, INCBDGT_ELIMOBJ_CD VARCHAR2(4)
, EXPBDGT_ELIMOBJ_CD VARCHAR2(4)
, RPTS_TO_FIN_COA_CD VARCHAR2(2)
, FIN_AR_OBJ_CD VARCHAR2(4)
, FIN_INT_ENC_OBJ_CD VARCHAR2(4)
, FIN_EXT_ENC_OBJ_CD VARCHAR2(4)
, FIN_PRE_ENC_OBJ_CD VARCHAR2(4)
, ICR_INC_FIN_OBJ_CD VARCHAR2(4)
, ICR_EXP_FIN_OBJ_CD VARCHAR2(4)
, FND_BAL_OBJ_CD VARCHAR2(4)
, CONSTRAINT CA_CHART_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_CHART_T
ADD CONSTRAINT CA_CHART_TP1
PRIMARY KEY (FIN_COA_CD)
/
-----------------------------------------------------------------------------
-- CA_DLGT_CHG_DOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_DLGT_CHG_DOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_DLGT_CHG_DOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_DLGT_CHG_DOC_T
(
FDOC_NBR VARCHAR2(14)
, ACCT_DLGT_UNVL_ID VARCHAR2(40)
, FDOC_TYP_CD VARCHAR2(64)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_APRV_FROM_AMT NUMBER(19,2)
, FDOC_APRV_TO_AMT NUMBER(19,2)
, ACCT_DLGT_PRMRT_CD VARCHAR2(1)
, ACCT_DLGT_START_DT DATE
, CONSTRAINT CA_DLGT_CHG_DOC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_DLGT_CHG_DOC_T
ADD CONSTRAINT CA_DLGT_CHG_DOC_TP1
PRIMARY KEY (FDOC_NBR,ACCT_DLGT_UNVL_ID,FDOC_TYP_CD)
/
CREATE INDEX CA_DLGT_CHG_DOC_TI2
ON CA_DLGT_CHG_DOC_T
(FDOC_NBR)
/
CREATE INDEX CA_DLGT_CHG_DOC_TI3
ON CA_DLGT_CHG_DOC_T
(ACCT_DLGT_UNVL_ID)
/
-----------------------------------------------------------------------------
-- CA_FEDERAL_FUNC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_FEDERAL_FUNC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_FEDERAL_FUNC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_FEDERAL_FUNC_T
(
FIN_FED_FUNC_CD VARCHAR2(3)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FIN_FED_FUNC_NM VARCHAR2(40)
, ROW_ACTV_IND VARCHAR2(1) default 'Y' NOT NULL
, CONSTRAINT CA_FEDERAL_FUNC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_FEDERAL_FUNC_T
ADD CONSTRAINT CA_FEDERAL_FUNC_TP1
PRIMARY KEY (FIN_FED_FUNC_CD)
/
-----------------------------------------------------------------------------
-- CA_FED_FND_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_FED_FND_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_FED_FND_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_FED_FND_T
(
FIN_FED_FUNDED_CD VARCHAR2(1)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, FIN_FED_FND_NM VARCHAR2(40)
, CONSTRAINT CA_FED_FND_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_FED_FND_T
ADD CONSTRAINT CA_FED_FND_TP1
PRIMARY KEY (FIN_FED_FUNDED_CD)
/
-----------------------------------------------------------------------------
-- CA_FUND_GRP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_FUND_GRP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_FUND_GRP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_FUND_GRP_T
(
FUND_GRP_CD VARCHAR2(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, FUND_GRP_NM VARCHAR2(40)
, FIN_REPORT_SORT_CD VARCHAR2(2)
, FND_GRP_BA_RSTR_LVL_CD VARCHAR2(1) default 'F' NOT NULL
, CONSTRAINT CA_FUND_GRP_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_FUND_GRP_T
ADD CONSTRAINT CA_FUND_GRP_TP1
PRIMARY KEY (FUND_GRP_CD)
/
-----------------------------------------------------------------------------
-- CA_HIGHR_ED_FUNC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_HIGHR_ED_FUNC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_HIGHR_ED_FUNC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_HIGHR_ED_FUNC_T
(
FIN_HGH_ED_FUNC_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FIN_HGH_ED_FUNC_NM VARCHAR2(40)
, FIN_UBO_FUNC_CD VARCHAR2(3)
, FIN_AICPA_FUNC_CD VARCHAR2(3)
, FIN_FED_FUNC_CD VARCHAR2(3)
, ROW_ACTV_IND VARCHAR2(1) default 'Y' NOT NULL
, CONSTRAINT CA_HIGHR_ED_FUNC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_HIGHR_ED_FUNC_T
ADD CONSTRAINT CA_HIGHR_ED_FUNC_TP1
PRIMARY KEY (FIN_HGH_ED_FUNC_CD)
/
-----------------------------------------------------------------------------
-- CA_ICR_ACCT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_ICR_ACCT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_ICR_ACCT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_ICR_ACCT_T
(
CA_ICR_ACCT_GNRTD_ID NUMBER(10) default 0
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FIN_COA_CD VARCHAR2(2) NOT NULL
, ACCOUNT_NBR VARCHAR2(7) NOT NULL
, ICR_FIN_COA_CD VARCHAR2(2)
, ICR_FIN_ACCT_NBR VARCHAR2(7)
, ACLN_PCT VARCHAR2(45)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
)
/
ALTER TABLE CA_ICR_ACCT_T
ADD CONSTRAINT CA_ICR_ACCT_TP1
PRIMARY KEY (CA_ICR_ACCT_GNRTD_ID)
/
-----------------------------------------------------------------------------
-- CA_ICR_AUTO_ENTR_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_ICR_AUTO_ENTR_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_ICR_AUTO_ENTR_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_ICR_AUTO_ENTR_T
(
UNIV_FISCAL_YR NUMBER(4)
, FIN_SERIES_ID VARCHAR2(3)
, AWRD_ICR_ENTRY_NBR NUMBER(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_OBJECT_CD VARCHAR2(4)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, TRN_DEBIT_CRDT_CD VARCHAR2(1)
, AWRD_ICR_RATE_PCT NUMBER(6,3)
, ACCT_ICR_RATE_ACTV_IND VARCHAR2(1)
)
/
ALTER TABLE CA_ICR_AUTO_ENTR_T
ADD CONSTRAINT CA_ICR_AUTO_ENTR_TP1
PRIMARY KEY (UNIV_FISCAL_YR,FIN_SERIES_ID,AWRD_ICR_ENTRY_NBR)
/
-----------------------------------------------------------------------------
-- CA_ICR_EXCL_ACCT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_ICR_EXCL_ACCT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_ICR_EXCL_ACCT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_ICR_EXCL_ACCT_T
(
FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, FIN_OBJ_COA_CD VARCHAR2(2)
, FIN_OBJECT_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ACTV_IND VARCHAR2(1)
, CONSTRAINT CA_ICR_EXCL_ACCT_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_ICR_EXCL_ACCT_T
ADD CONSTRAINT CA_ICR_EXCL_ACCT_TP1
PRIMARY KEY (FIN_COA_CD,ACCOUNT_NBR,FIN_OBJ_COA_CD,FIN_OBJECT_CD)
/
-----------------------------------------------------------------------------
-- CA_ICR_EXCL_TYPE_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_ICR_EXCL_TYPE_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_ICR_EXCL_TYPE_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_ICR_EXCL_TYPE_T
(
ACCT_ICR_TYP_CD VARCHAR2(2)
, FIN_COA_CD VARCHAR2(2)
, FIN_OBJECT_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ACCT_ICR_EXCL_TYP_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT CA_ICR_EXCL_TYPE_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_ICR_EXCL_TYPE_T
ADD CONSTRAINT CA_ICR_EXCL_TYPE_TP1
PRIMARY KEY (ACCT_ICR_TYP_CD,FIN_COA_CD,FIN_OBJECT_CD)
/
-----------------------------------------------------------------------------
-- CA_ICR_RATE_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_ICR_RATE_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_ICR_RATE_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_ICR_RATE_T
(
UNIV_FISCAL_YR NUMBER(4)
, FIN_SERIES_ID VARCHAR2(3)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT CA_ICR_RATE_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_ICR_RATE_T
ADD CONSTRAINT CA_ICR_RATE_TP1
PRIMARY KEY (UNIV_FISCAL_YR,FIN_SERIES_ID)
/
-----------------------------------------------------------------------------
-- CA_ICR_TYPE_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_ICR_TYPE_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_ICR_TYPE_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_ICR_TYPE_T
(
ACCT_ICR_TYP_CD VARCHAR2(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ACCT_ICR_TYP_DESC VARCHAR2(40)
, ACCT_ICR_TYP_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT CA_ICR_TYPE_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_ICR_TYPE_T
ADD CONSTRAINT CA_ICR_TYPE_TP1
PRIMARY KEY (ACCT_ICR_TYP_CD)
/
-----------------------------------------------------------------------------
-- CA_MNXFR_ELIM_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_MNXFR_ELIM_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_MNXFR_ELIM_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_MNXFR_ELIM_T
(
FOBJ_MNXFR_ELIM_CD VARCHAR2(1)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, FOBJ_MNXFR_ELIM_NM VARCHAR2(40)
, CONSTRAINT CA_MNXFR_ELIM_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_MNXFR_ELIM_T
ADD CONSTRAINT CA_MNXFR_ELIM_TP1
PRIMARY KEY (FOBJ_MNXFR_ELIM_CD)
/
-----------------------------------------------------------------------------
-- CA_OBJECT_CODE_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_OBJECT_CODE_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_OBJECT_CODE_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_OBJECT_CODE_T
(
UNIV_FISCAL_YR NUMBER(4)
, FIN_COA_CD VARCHAR2(2)
, FIN_OBJECT_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FIN_OBJ_CD_NM VARCHAR2(40)
, FIN_OBJ_CD_SHRT_NM VARCHAR2(12)
, FIN_OBJ_LEVEL_CD VARCHAR2(4)
, RPTS_TO_FIN_COA_CD VARCHAR2(2)
, RPTS_TO_FIN_OBJ_CD VARCHAR2(4)
, FIN_OBJ_TYP_CD VARCHAR2(2)
, FIN_OBJ_SUB_TYP_CD VARCHAR2(2)
, HIST_FIN_OBJECT_CD VARCHAR2(4)
, FIN_OBJ_ACTIVE_CD VARCHAR2(1)
, FOBJ_BDGT_AGGR_CD VARCHAR2(1)
, FOBJ_MNXFR_ELIM_CD VARCHAR2(1)
, FIN_FED_FUNDED_CD VARCHAR2(1)
, NXT_YR_FIN_OBJ_CD VARCHAR2(4)
, RSCH_BDGT_CTGRY_CD VARCHAR2(3)
, RSCH_OBJ_CD_DESC VARCHAR2(200)
, RSCH_ON_CMP_IND VARCHAR2(1)
, CONSTRAINT CA_OBJECT_CODE_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_OBJECT_CODE_T
ADD CONSTRAINT CA_OBJECT_CODE_TP1
PRIMARY KEY (UNIV_FISCAL_YR,FIN_COA_CD,FIN_OBJECT_CD)
/
-----------------------------------------------------------------------------
-- CA_OBJ_CD_CHG_DOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_OBJ_CD_CHG_DOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_OBJ_CD_CHG_DOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_OBJ_CD_CHG_DOC_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, UNIV_FISCAL_YR NUMBER(4)
, FIN_COA_CD VARCHAR2(2)
, FIN_OBJECT_CD VARCHAR2(4)
, FIN_OBJ_CD_NM VARCHAR2(40)
, FIN_OBJ_CD_SHRT_NM VARCHAR2(12)
, FIN_OBJ_LEVEL_CD VARCHAR2(4)
, RPTS_TO_FIN_COA_CD VARCHAR2(2)
, RPTS_TO_FIN_OBJ_CD VARCHAR2(4)
, FIN_OBJ_TYP_CD VARCHAR2(2)
, FIN_OBJ_SUB_TYP_CD VARCHAR2(2)
, HIST_FIN_OBJECT_CD VARCHAR2(4)
, FIN_OBJ_ACTIVE_CD VARCHAR2(1)
, FOBJ_BDGT_AGGR_CD VARCHAR2(1)
, FOBJ_MNXFR_ELIM_CD VARCHAR2(1)
, FIN_FED_FUNDED_CD VARCHAR2(1)
, NXT_YR_FIN_OBJ_CD VARCHAR2(4)
, RSCH_BDGT_CTGRY_CD VARCHAR2(3)
, RSCH_OBJ_CD_DESC VARCHAR2(200)
, RSCH_ON_CMP_IND VARCHAR2(1)
, CONSTRAINT CA_OBJ_CD_CHG_DOC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_OBJ_CD_CHG_DOC_T
ADD CONSTRAINT CA_OBJ_CD_CHG_DOC_TP1
PRIMARY KEY (FDOC_NBR)
/
CREATE INDEX CA_OBJ_CD_CHG_DOC_TI1
ON CA_OBJ_CD_CHG_DOC_T
(UNIV_FISCAL_YR)
/
-----------------------------------------------------------------------------
-- CA_OBJ_CD_CHG_DTL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_OBJ_CD_CHG_DTL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_OBJ_CD_CHG_DTL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_OBJ_CD_CHG_DTL_T
(
FDOC_NBR VARCHAR2(14)
, UNIV_FISCAL_YR NUMBER(4)
, FIN_COA_CD VARCHAR2(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CONSTRAINT CA_OBJ_CD_CHG_DTL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_OBJ_CD_CHG_DTL_T
ADD CONSTRAINT CA_OBJ_CD_CHG_DTL_TP1
PRIMARY KEY (FDOC_NBR,UNIV_FISCAL_YR,FIN_COA_CD)
/
-----------------------------------------------------------------------------
-- CA_OBJ_CONSOLDTN_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_OBJ_CONSOLDTN_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_OBJ_CONSOLDTN_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_OBJ_CONSOLDTN_T
(
FIN_COA_CD VARCHAR2(2)
, FIN_CONS_OBJ_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FIN_CONS_OBJ_NM VARCHAR2(40)
, FIN_CONOBJ_SHRT_NM VARCHAR2(12)
, FIN_CONOBJ_ACTV_CD VARCHAR2(1)
, FIN_REPORT_SORT_CD VARCHAR2(2)
, CONSTRAINT CA_OBJ_CONSOLDTN_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_OBJ_CONSOLDTN_T
ADD CONSTRAINT CA_OBJ_CONSOLDTN_TP1
PRIMARY KEY (FIN_COA_CD,FIN_CONS_OBJ_CD)
/
-----------------------------------------------------------------------------
-- CA_OBJ_LEVEL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_OBJ_LEVEL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_OBJ_LEVEL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_OBJ_LEVEL_T
(
FIN_COA_CD VARCHAR2(2)
, FIN_OBJ_LEVEL_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FIN_OBJ_LEVEL_NM VARCHAR2(40)
, FIN_OBJLVL_SHRT_NM VARCHAR2(12)
, FIN_CONS_OBJ_CD VARCHAR2(4)
, FIN_OBJLVL_ACTV_CD VARCHAR2(1)
, FIN_REPORT_SORT_CD VARCHAR2(2)
, CONSTRAINT CA_OBJ_LEVEL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_OBJ_LEVEL_T
ADD CONSTRAINT CA_OBJ_LEVEL_TP1
PRIMARY KEY (FIN_COA_CD,FIN_OBJ_LEVEL_CD)
/
CREATE INDEX CA_OBJ_LEVEL_TI2
ON CA_OBJ_LEVEL_T
(FIN_COA_CD, FIN_CONS_OBJ_CD)
/
-----------------------------------------------------------------------------
-- CA_OBJ_SUB_TYPE_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_OBJ_SUB_TYPE_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_OBJ_SUB_TYPE_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_OBJ_SUB_TYPE_T
(
FIN_OBJ_SUB_TYP_CD VARCHAR2(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FIN_OBJ_SUB_TYP_NM VARCHAR2(40)
, ROW_ACTV_IND VARCHAR2(1) default 'Y' NOT NULL
, CONSTRAINT CA_OBJ_SUB_TYPE_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_OBJ_SUB_TYPE_T
ADD CONSTRAINT CA_OBJ_SUB_TYPE_TP1
PRIMARY KEY (FIN_OBJ_SUB_TYP_CD)
/
-----------------------------------------------------------------------------
-- CA_OBJ_TYPE_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_OBJ_TYPE_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_OBJ_TYPE_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_OBJ_TYPE_T
(
FIN_OBJ_TYP_CD VARCHAR2(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FIN_OBJ_TYP_NM VARCHAR2(40)
, FIN_OBJTYP_DBCR_CD VARCHAR2(1)
, FIN_OBJ_TYP_ICR_CD VARCHAR2(1)
, FUND_BALANCE_CD VARCHAR2(1)
, FIN_REPORT_SORT_CD VARCHAR2(2)
, ACCTG_CTGRY_CD VARCHAR2(2) NOT NULL
, ROW_ACTV_IND VARCHAR2(1) default 'Y' NOT NULL
, CONSTRAINT CA_OBJ_TYPE_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_OBJ_TYPE_T
ADD CONSTRAINT CA_OBJ_TYPE_TP1
PRIMARY KEY (FIN_OBJ_TYP_CD)
/
-----------------------------------------------------------------------------
-- CA_ORG_EXTNS_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_ORG_EXTNS_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_ORG_EXTNS_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_ORG_EXTNS_T
(
FIN_COA_CD VARCHAR2(2)
, ORG_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, DESCRSHORT VARCHAR2(10)
, COMPANY VARCHAR2(3)
, SETID_LOCATION VARCHAR2(5)
, LOCATION VARCHAR2(10)
, TAX_LOCATION_CD VARCHAR2(10)
, MANAGER_UNVL_ID VARCHAR2(40)
, MANAGER_POSN VARCHAR2(8)
, BUDGET_YR_END_DT NUMBER(4)
, BUDGET_LVL VARCHAR2(1)
, GL_EXPENSE VARCHAR2(35)
, EEO4_FUNCTION VARCHAR2(2)
, ACCIDENT_INS VARCHAR2(3)
, SI_ACCIDENT_NUM VARCHAR2(15)
, HAZARD VARCHAR2(4)
, ESTABID VARCHAR2(5)
, RISKCD VARCHAR2(6)
, FTE_EDIT_INDC VARCHAR2(1)
, DEPT_TENURE_FLG VARCHAR2(1)
, TL_DISTRIB_INFO VARCHAR2(1)
, USE_BUDGETS VARCHAR2(1)
, USE_ENCUMBRANCES VARCHAR2(1)
, USE_DISTRIBUTION VARCHAR2(1)
, BUDGET_DEPTID VARCHAR2(10)
, DIST_PRORATE_OPTN VARCHAR2(1)
, HP_STATS_DEPT_CD VARCHAR2(3)
, HP_STATS_FACULTY VARCHAR2(5)
, ACCOUNTING_OWNER VARCHAR2(30)
, COUNTRY_GRP VARCHAR2(18)
, IU_ORG_MAIL_DRP_CD VARCHAR2(15)
, IU_ORG_ADDRESS_2 VARCHAR2(30)
, IU_ORG_ADDRESS_3 VARCHAR2(30)
, IU_CAMPUS_CD VARCHAR2(2)
, IU_CAMPUS_BLDG VARCHAR2(10)
, IU_CAMPUS_ROOM VARCHAR2(8)
, IU_POSN_ALLOW_FL VARCHAR2(1)
, IU_TENURE_ALLOW_FL VARCHAR2(1)
, IU_TITLE_ALLOW_FL VARCHAR2(1)
, IU_OCC_UN_ALLOW_FL VARCHAR2(1)
, ORG_FSCL_APRVR_UID VARCHAR2(40)
, LAST_UPDATE_DATE DATE
, CONSTRAINT CA_ORG_EXTNS_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_ORG_EXTNS_T
ADD CONSTRAINT CA_ORG_EXTNS_TP1
PRIMARY KEY (FIN_COA_CD,ORG_CD)
/
-----------------------------------------------------------------------------
-- CA_ORG_REVERSION_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_ORG_REVERSION_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_ORG_REVERSION_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_ORG_REVERSION_T
(
UNIV_FISCAL_YR NUMBER(4)
, FIN_COA_CD VARCHAR2(2)
, ORG_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, BDGT_RVRSN_COA_CD VARCHAR2(2)
, BDGT_RVRSNACCT_NBR VARCHAR2(7)
, CF_BY_OBJ_CD_IND VARCHAR2(1)
, CSH_RVRSNFINCOA_CD VARCHAR2(2)
, CSH_RVRSN_ACCT_NBR VARCHAR2(7)
, ROW_ACTV_IND VARCHAR2(1) default 'Y' NOT NULL
, CONSTRAINT CA_ORG_REVERSION_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_ORG_REVERSION_T
ADD CONSTRAINT CA_ORG_REVERSION_TP1
PRIMARY KEY (UNIV_FISCAL_YR,FIN_COA_CD,ORG_CD)
/
-----------------------------------------------------------------------------
-- CA_ORG_RTNG_MDL_NM_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_ORG_RTNG_MDL_NM_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_ORG_RTNG_MDL_NM_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_ORG_RTNG_MDL_NM_T
(
FIN_COA_CD VARCHAR2(2)
, ORG_CD VARCHAR2(4)
, ORG_RTNG_MDL_NM VARCHAR2(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ROW_ACTV_IND VARCHAR2(1) default 'Y' NOT NULL
, CONSTRAINT CA_ORG_RTNG_MDL_NM_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_ORG_RTNG_MDL_NM_T
ADD CONSTRAINT CA_ORG_RTNG_MDL_NM_TP1
PRIMARY KEY (FIN_COA_CD,ORG_CD,ORG_RTNG_MDL_NM)
/
-----------------------------------------------------------------------------
-- CA_ORG_RTNG_MDL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_ORG_RTNG_MDL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_ORG_RTNG_MDL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_ORG_RTNG_MDL_T
(
FIN_COA_CD VARCHAR2(2)
, ORG_CD VARCHAR2(4)
, ORG_RTNG_MDL_NM VARCHAR2(10)
, ACCT_DLGT_UNVL_ID VARCHAR2(40)
, FDOC_TYP_CD VARCHAR2(8)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_APRV_FROM_AMT NUMBER(19,2)
, FDOC_APRV_TO_AMT NUMBER(19,2)
, ACCT_DLGT_PRMRT_CD VARCHAR2(1)
, ACCT_DLGT_START_DT DATE
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT CA_ORG_RTNG_MDL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_ORG_RTNG_MDL_T
ADD CONSTRAINT CA_ORG_RTNG_MDL_TP1
PRIMARY KEY (FIN_COA_CD,ORG_CD,ORG_RTNG_MDL_NM,ACCT_DLGT_UNVL_ID,FDOC_TYP_CD)
/
CREATE INDEX CA_ORG_RTNG_MDL_TI2
ON CA_ORG_RTNG_MDL_T
(ACCT_DLGT_UNVL_ID)
/
-----------------------------------------------------------------------------
-- CA_ORG_RVRSN_CHG_DOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_ORG_RVRSN_CHG_DOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_ORG_RVRSN_CHG_DOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_ORG_RVRSN_CHG_DOC_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, UNIV_FISCAL_YR NUMBER(4)
, BDGT_RVRSN_COA_CD VARCHAR2(2)
, BDGT_RVRSNACCT_NBR VARCHAR2(7)
, CF_BY_OBJ_CD_IND VARCHAR2(1)
, CSH_RVRSNFINCOA_CD VARCHAR2(2)
, CSH_RVRSN_ACCT_NBR VARCHAR2(7)
, CONSTRAINT CA_ORG_RVRSN_CHG_DOC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_ORG_RVRSN_CHG_DOC_T
ADD CONSTRAINT CA_ORG_RVRSN_CHG_DOC_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- CA_ORG_RVRSN_CHG_DTL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_ORG_RVRSN_CHG_DTL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_ORG_RVRSN_CHG_DTL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_ORG_RVRSN_CHG_DTL_T
(
FDOC_NBR VARCHAR2(14)
, ORG_RVRSN_CTGRY_CD VARCHAR2(8)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ORG_RVRSN_OBJ_CD VARCHAR2(4)
, ORG_RVRSN_CD VARCHAR2(2)
, CONSTRAINT CA_ORG_RVRSN_CHG_DTL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_ORG_RVRSN_CHG_DTL_T
ADD CONSTRAINT CA_ORG_RVRSN_CHG_DTL_TP1
PRIMARY KEY (FDOC_NBR,ORG_RVRSN_CTGRY_CD)
/
-----------------------------------------------------------------------------
-- CA_ORG_RVRSN_CHG_ORG_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_ORG_RVRSN_CHG_ORG_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_ORG_RVRSN_CHG_ORG_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_ORG_RVRSN_CHG_ORG_T
(
FDOC_NBR VARCHAR2(14)
, FIN_COA_CD VARCHAR2(2)
, ORG_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CONSTRAINT CA_ORG_RVRSN_CHG_ORG_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_ORG_RVRSN_CHG_ORG_T
ADD CONSTRAINT CA_ORG_RVRSN_CHG_ORG_TP1
PRIMARY KEY (FDOC_NBR,FIN_COA_CD,ORG_CD)
/
-----------------------------------------------------------------------------
-- CA_ORG_RVRSN_CTGRY_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_ORG_RVRSN_CTGRY_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_ORG_RVRSN_CTGRY_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_ORG_RVRSN_CTGRY_T
(
ORG_RVRSN_CTGRY_CD VARCHAR2(8)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ORG_RVRSN_CTGRY_NM VARCHAR2(40)
, ORG_RVRSN_SORT_CD VARCHAR2(2)
, ORG_RVRSN_CTGRY_ACTV_IND VARCHAR2(1) default 'Y' NOT NULL
, CONSTRAINT CA_ORG_RVRSN_CTGRY_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_ORG_RVRSN_CTGRY_T
ADD CONSTRAINT CA_ORG_RVRSN_CTGRY_TP1
PRIMARY KEY (ORG_RVRSN_CTGRY_CD)
/
-----------------------------------------------------------------------------
-- CA_ORG_RVRSN_DTL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_ORG_RVRSN_DTL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_ORG_RVRSN_DTL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_ORG_RVRSN_DTL_T
(
UNIV_FISCAL_YR NUMBER(4)
, FIN_COA_CD VARCHAR2(2)
, ORG_CD VARCHAR2(4)
, ORG_RVRSN_CTGRY_CD VARCHAR2(8)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ORG_RVRSN_CD VARCHAR2(2)
, ORG_RVRSN_OBJ_CD VARCHAR2(4)
, ACTV_IND VARCHAR2(1)
, CONSTRAINT CA_ORG_RVRSN_DTL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_ORG_RVRSN_DTL_T
ADD CONSTRAINT CA_ORG_RVRSN_DTL_TP1
PRIMARY KEY (UNIV_FISCAL_YR,FIN_COA_CD,ORG_CD,ORG_RVRSN_CTGRY_CD)
/
-----------------------------------------------------------------------------
-- CA_ORG_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_ORG_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_ORG_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_ORG_T
(
FIN_COA_CD VARCHAR2(2)
, ORG_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ORG_MGR_UNVL_ID VARCHAR2(40)
, ORG_NM VARCHAR2(40)
, RC_CD VARCHAR2(2)
, ORG_PHYS_CMP_CD VARCHAR2(2)
, ORG_TYP_CD VARCHAR2(1)
, ORG_DFLT_ACCT_NBR VARCHAR2(7)
, ORG_LN1_ADDR VARCHAR2(30)
, ORG_LN2_ADDR VARCHAR2(30)
, ORG_CITY_NM VARCHAR2(25)
, ORG_STATE_CD VARCHAR2(2)
, ORG_ZIP_CD VARCHAR2(20)
, ORG_CNTRY_CD VARCHAR2(2)
, ORG_BEGIN_DT DATE
, ORG_END_DT DATE
, RPTS_TO_FIN_COA_CD VARCHAR2(2)
, RPTS_TO_ORG_CD VARCHAR2(4)
, ORG_ACTIVE_CD VARCHAR2(1)
, ORG_IN_FP_CD VARCHAR2(1)
, ORG_PLNT_ACCT_NBR VARCHAR2(7)
, CMP_PLNT_ACCT_NBR VARCHAR2(7)
, ORG_PLNT_COA_CD VARCHAR2(2)
, CMP_PLNT_COA_CD VARCHAR2(2)
, CONSTRAINT CA_ORG_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_ORG_T
ADD CONSTRAINT CA_ORG_TP1
PRIMARY KEY (FIN_COA_CD,ORG_CD)
/
CREATE INDEX CA_ORG_TI2
ON CA_ORG_T
(ORG_TYP_CD)
/
CREATE INDEX CA_ORG_TI3
ON CA_ORG_T
(RC_CD)
/
CREATE INDEX CA_ORG_TI4
ON CA_ORG_T
(ORG_MGR_UNVL_ID)
/
CREATE INDEX CA_ORG_TI5
ON CA_ORG_T
(RPTS_TO_FIN_COA_CD, RPTS_TO_ORG_CD)
/
-----------------------------------------------------------------------------
-- CA_ORG_TYPE_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_ORG_TYPE_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_ORG_TYPE_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_ORG_TYPE_T
(
ORG_TYP_CD VARCHAR2(1)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ORG_TYP_NM VARCHAR2(40)
, ROW_ACTV_IND VARCHAR2(1) default 'Y' NOT NULL
, CONSTRAINT CA_ORG_TYPE_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_ORG_TYPE_T
ADD CONSTRAINT CA_ORG_TYPE_TP1
PRIMARY KEY (ORG_TYP_CD)
/
-----------------------------------------------------------------------------
-- CA_PRIOR_YR_ACCT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_PRIOR_YR_ACCT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_PRIOR_YR_ACCT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_PRIOR_YR_ACCT_T
(
FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ACCOUNT_NM VARCHAR2(40)
, ACCT_FSC_OFC_UID VARCHAR2(40)
, ACCT_SPVSR_UNVL_ID VARCHAR2(40)
, ACCT_MGR_UNVL_ID VARCHAR2(40)
, ORG_CD VARCHAR2(4)
, ACCT_TYP_CD VARCHAR2(2)
, ACCT_PHYS_CMP_CD VARCHAR2(2)
, SUB_FUND_GRP_CD VARCHAR2(6)
, ACCT_FRNG_BNFT_CD VARCHAR2(1)
, FIN_HGH_ED_FUNC_CD VARCHAR2(4)
, ACCT_RSTRC_STAT_CD VARCHAR2(1)
, ACCT_RSTRC_STAT_DT DATE
, ACCT_CITY_NM VARCHAR2(25)
, ACCT_STATE_CD VARCHAR2(2)
, ACCT_STREET_ADDR VARCHAR2(30)
, ACCT_ZIP_CD VARCHAR2(20)
, RPTS_TO_FIN_COA_CD VARCHAR2(2)
, RPTS_TO_ACCT_NBR VARCHAR2(7)
, ACCT_CREATE_DT DATE
, ACCT_EFFECT_DT DATE
, ACCT_EXPIRATION_DT DATE
, CONT_FIN_COA_CD VARCHAR2(2)
, CONT_ACCOUNT_NBR VARCHAR2(7)
, ENDOW_FIN_COA_CD VARCHAR2(2)
, ENDOW_ACCOUNT_NBR VARCHAR2(7)
, CONTR_CTRL_FCOA_CD VARCHAR2(2)
, CONTR_CTRLACCT_NBR VARCHAR2(7)
, INCOME_FIN_COA_CD VARCHAR2(2)
, INCOME_ACCOUNT_NBR VARCHAR2(7)
, ACCT_ICR_TYP_CD VARCHAR2(2)
, AC_CSTM_ICREXCL_CD VARCHAR2(1)
, FIN_SERIES_ID VARCHAR2(3)
, ICR_FIN_COA_CD VARCHAR2(2)
, ICR_ACCOUNT_NBR VARCHAR2(7)
, ACCT_IN_FP_CD VARCHAR2(1)
, BDGT_REC_LVL_CD VARCHAR2(1)
, ACCT_SF_CD VARCHAR2(1)
, ACCT_PND_SF_CD VARCHAR2(1)
, FIN_EXT_ENC_SF_CD VARCHAR2(1)
, FIN_INT_ENC_SF_CD VARCHAR2(1)
, FIN_PRE_ENC_SF_CD VARCHAR2(1)
, FIN_OBJ_PRSCTRL_CD VARCHAR2(1)
, CG_CFDA_NBR VARCHAR2(6)
, ACCT_OFF_CMP_IND VARCHAR2(1)
, ACCT_CLOSED_IND VARCHAR2(1)
, CONSTRAINT CA_PRIOR_YR_ACCT_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_PRIOR_YR_ACCT_T
ADD CONSTRAINT CA_PRIOR_YR_ACCT_TP1
PRIMARY KEY (FIN_COA_CD,ACCOUNT_NBR)
/
-----------------------------------------------------------------------------
-- CA_PRIOR_YR_ICR_ACCT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_PRIOR_YR_ICR_ACCT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_PRIOR_YR_ICR_ACCT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_PRIOR_YR_ICR_ACCT_T
(
CA_PRIOR_YR_ICR_ACCT_GNRTD_ID NUMBER(10) default 0
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FIN_COA_CD VARCHAR2(2) NOT NULL
, ACCOUNT_NBR VARCHAR2(7) NOT NULL
, ICR_FIN_COA_CD VARCHAR2(2)
, ICR_FIN_ACCT_NBR VARCHAR2(7)
, ACLN_PCT VARCHAR2(45)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
)
/
ALTER TABLE CA_PRIOR_YR_ICR_ACCT_T
ADD CONSTRAINT CA_PRIOR_YR_ICR_ACCT_TP1
PRIMARY KEY (CA_PRIOR_YR_ICR_ACCT_GNRTD_ID)
/
-----------------------------------------------------------------------------
-- CA_PRIOR_YR_ORG_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_PRIOR_YR_ORG_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_PRIOR_YR_ORG_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_PRIOR_YR_ORG_T
(
FIN_COA_CD VARCHAR2(2)
, ORG_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ORG_MGR_UNVL_ID VARCHAR2(40)
, ORG_NM VARCHAR2(40)
, RC_CD VARCHAR2(2)
, ORG_PHYS_CMP_CD VARCHAR2(2)
, ORG_TYP_CD VARCHAR2(1)
, ORG_DFLT_ACCT_NBR VARCHAR2(7)
, ORG_LN1_ADDR VARCHAR2(30)
, ORG_LN2_ADDR VARCHAR2(30)
, ORG_CITY_NM VARCHAR2(25)
, ORG_STATE_CD VARCHAR2(2)
, ORG_ZIP_CD VARCHAR2(20)
, ORG_CNTRY_CD VARCHAR2(2)
, ORG_BEGIN_DT DATE
, ORG_END_DT DATE
, RPTS_TO_FIN_COA_CD VARCHAR2(2)
, RPTS_TO_ORG_CD VARCHAR2(4)
, ORG_ACTIVE_CD VARCHAR2(1)
, ORG_IN_FP_CD VARCHAR2(1)
, ORG_PLNT_ACCT_NBR VARCHAR2(7)
, CMP_PLNT_ACCT_NBR VARCHAR2(7)
, ORG_PLNT_COA_CD VARCHAR2(2)
, CMP_PLNT_COA_CD VARCHAR2(2)
, CONSTRAINT CA_PRIOR_YR_ORG_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_PRIOR_YR_ORG_T
ADD CONSTRAINT CA_PRIOR_YR_ORG_TP1
PRIMARY KEY (FIN_COA_CD,ORG_CD)
/
CREATE INDEX CA_PRIOR_YR_ORG_TI2
ON CA_PRIOR_YR_ORG_T
(ORG_TYP_CD)
/
CREATE INDEX CA_PRIOR_YR_ORG_TI3
ON CA_PRIOR_YR_ORG_T
(RC_CD)
/
CREATE INDEX CA_PRIOR_YR_ORG_TI4
ON CA_PRIOR_YR_ORG_T
(ORG_MGR_UNVL_ID)
/
CREATE INDEX CA_PRIOR_YR_ORG_TI5
ON CA_PRIOR_YR_ORG_T
(RPTS_TO_FIN_COA_CD, RPTS_TO_ORG_CD)
/
-----------------------------------------------------------------------------
-- CA_PROJECT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_PROJECT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_PROJECT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_PROJECT_T
(
PROJECT_CD VARCHAR2(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, PROJ_MGR_UNVL_ID VARCHAR2(40)
, PROJECT_NM VARCHAR2(40)
, FIN_COA_CD VARCHAR2(2)
, ORG_CD VARCHAR2(4)
, PROJ_ACTIVE_CD VARCHAR2(1)
, PROJECT_DESC VARCHAR2(400)
, CONSTRAINT CA_PROJECT_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_PROJECT_T
ADD CONSTRAINT CA_PROJECT_TP1
PRIMARY KEY (PROJECT_CD)
/
CREATE INDEX CA_PROJECT_TI2
ON CA_PROJECT_T
(FIN_COA_CD, ORG_CD)
/
CREATE INDEX CA_PROJECT_TI3
ON CA_PROJECT_T
(PROJ_MGR_UNVL_ID)
/
-----------------------------------------------------------------------------
-- CA_RC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_RC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_RC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_RC_T
(
RC_CD VARCHAR2(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, RC_NM VARCHAR2(40)
, RC_SHRT_NM VARCHAR2(12)
, RC_ACTIVE_CD VARCHAR2(1)
, CONSTRAINT CA_RC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_RC_T
ADD CONSTRAINT CA_RC_TP1
PRIMARY KEY (RC_CD)
/
-----------------------------------------------------------------------------
-- CA_RESTRICT_STAT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_RESTRICT_STAT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_RESTRICT_STAT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_RESTRICT_STAT_T
(
ACCT_RSTRC_STAT_CD VARCHAR2(1)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ACCT_RSTRC_STAT_NM VARCHAR2(40)
, ROW_ACTV_IND VARCHAR2(1) default 'Y' NOT NULL
, CONSTRAINT CA_RESTRICT_STAT_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_RESTRICT_STAT_T
ADD CONSTRAINT CA_RESTRICT_STAT_TP1
PRIMARY KEY (ACCT_RSTRC_STAT_CD)
/
-----------------------------------------------------------------------------
-- CA_SUB_ACCT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_SUB_ACCT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_SUB_ACCT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_SUB_ACCT_T
(
FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, SUB_ACCT_NBR VARCHAR2(5)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, SUB_ACCT_NM VARCHAR2(40)
, SUB_ACCT_ACTV_CD VARCHAR2(1)
, FIN_RPT_CHRT_CD VARCHAR2(2)
, FIN_RPT_ORG_CD VARCHAR2(4)
, FIN_RPT_CD VARCHAR2(10)
, CONSTRAINT CA_SUB_ACCT_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_SUB_ACCT_T
ADD CONSTRAINT CA_SUB_ACCT_TP1
PRIMARY KEY (FIN_COA_CD,ACCOUNT_NBR,SUB_ACCT_NBR)
/
CREATE INDEX CA_SUB_ACCT_TI2
ON CA_SUB_ACCT_T
(FIN_COA_CD, ACCOUNT_NBR)
/
-----------------------------------------------------------------------------
-- CA_SUB_FND_GRP_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_SUB_FND_GRP_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_SUB_FND_GRP_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_SUB_FND_GRP_TYP_T
(
SUB_FUNDGRP_TYP_CD VARCHAR2(1)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, SUB_FND_GRP_TYP_DESC VARCHAR2(40)
, SUB_FND_GRP_TYP_ACTV_IND VARCHAR2(1)
, CONSTRAINT CA_SUB_FND_GRP_TYP_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_SUB_FND_GRP_TYP_T
ADD CONSTRAINT CA_SUB_FND_GRP_TYP_TP1
PRIMARY KEY (SUB_FUNDGRP_TYP_CD)
/
-----------------------------------------------------------------------------
-- CA_SUB_FUND_GRP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_SUB_FUND_GRP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_SUB_FUND_GRP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_SUB_FUND_GRP_T
(
SUB_FUND_GRP_CD VARCHAR2(6)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FUND_GRP_CD VARCHAR2(2)
, SUB_FUND_GRP_DESC VARCHAR2(40)
, SUBFUNDGRP_ACTV_CD VARCHAR2(1)
, SUB_FUNDGRP_TYP_CD VARCHAR2(1)
, FIN_REPORT_SORT_CD VARCHAR2(2)
, SUB_FUND_GRP_WAGE_IND VARCHAR2(1)
, FND_GRP_BA_RSTR_LVL_CD VARCHAR2(1) default 'N' NOT NULL
, ACCT_RSTRC_STAT_CD VARCHAR2(1)
, CONSTRAINT CA_SUB_FUND_GRP_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_SUB_FUND_GRP_T
ADD CONSTRAINT CA_SUB_FUND_GRP_TP1
PRIMARY KEY (SUB_FUND_GRP_CD)
/
-----------------------------------------------------------------------------
-- CA_SUB_OBJECT_CD_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_SUB_OBJECT_CD_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_SUB_OBJECT_CD_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_SUB_OBJECT_CD_T
(
UNIV_FISCAL_YR NUMBER(4)
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, FIN_OBJECT_CD VARCHAR2(4)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FIN_SUB_OBJ_CD_NM VARCHAR2(40)
, FIN_SUBOBJ_SHRT_NM VARCHAR2(12)
, FIN_SUBOBJ_ACTV_CD VARCHAR2(1)
, CONSTRAINT CA_SUB_OBJECT_CD_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_SUB_OBJECT_CD_T
ADD CONSTRAINT CA_SUB_OBJECT_CD_TP1
PRIMARY KEY (UNIV_FISCAL_YR,FIN_COA_CD,ACCOUNT_NBR,FIN_OBJECT_CD,FIN_SUB_OBJ_CD)
/
-----------------------------------------------------------------------------
-- CA_SUB_OBJ_CD_CHG_DOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_SUB_OBJ_CD_CHG_DOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_SUB_OBJ_CD_CHG_DOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_SUB_OBJ_CD_CHG_DOC_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, UNIV_FISCAL_YR NUMBER(4)
, FIN_COA_CD VARCHAR2(2)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, FIN_SUB_OBJ_CD_NM VARCHAR2(40)
, FIN_SUBOBJ_SHRT_NM VARCHAR2(12)
, FIN_SUBOBJ_ACTV_CD VARCHAR2(1)
, CONSTRAINT CA_SUB_OBJ_CD_CHG_DOC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_SUB_OBJ_CD_CHG_DOC_T
ADD CONSTRAINT CA_SUB_OBJ_CD_CHG_DOC_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- CA_SUB_OBJ_CD_CHG_DTL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_SUB_OBJ_CD_CHG_DTL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_SUB_OBJ_CD_CHG_DTL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_SUB_OBJ_CD_CHG_DTL_T
(
FDOC_NBR VARCHAR2(14)
, UNIV_FISCAL_YR NUMBER(4)
, FIN_COA_CD VARCHAR2(2)
, FIN_OBJECT_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CONSTRAINT CA_SUB_OBJ_CD_CHG_DTL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_SUB_OBJ_CD_CHG_DTL_T
ADD CONSTRAINT CA_SUB_OBJ_CD_CHG_DTL_TP1
PRIMARY KEY (FDOC_NBR,UNIV_FISCAL_YR,FIN_COA_CD,FIN_OBJECT_CD)
/
-----------------------------------------------------------------------------
-- CA_UBO_FUNC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CA_UBO_FUNC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CA_UBO_FUNC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CA_UBO_FUNC_T
(
FIN_UBO_FUNC_CD VARCHAR2(3)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FIN_UBO_FUNC_NM VARCHAR2(40)
, ROW_ACTV_IND VARCHAR2(1) default 'Y' NOT NULL
, CONSTRAINT CA_UBO_FUNC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CA_UBO_FUNC_T
ADD CONSTRAINT CA_UBO_FUNC_TP1
PRIMARY KEY (FIN_UBO_FUNC_CD)
/
-----------------------------------------------------------------------------
-- CB_AST_TRN_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CB_AST_TRN_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CB_AST_TRN_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CB_AST_TRN_TYP_T
(
CPTL_AST_TRN_TYP_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CPTL_AST_TRN_TYP_DESC VARCHAR2(45) NOT NULL
, CPTL_AST_NON_QTY_DRVN_ALLW_IND VARCHAR2(1)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CPTLAST_QTY_SUBTYP_REQ_TXT VARCHAR2(100)
, CPTLAST_NONQTY_SUBTYP_REQ_TXT VARCHAR2(100)
, CONSTRAINT CB_AST_TRN_TYP_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CB_AST_TRN_TYP_T
ADD CONSTRAINT CB_AST_TRN_TYP_TP1
PRIMARY KEY (CPTL_AST_TRN_TYP_CD)
/
-----------------------------------------------------------------------------
-- CB_GL_ENTRY_AST_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CB_GL_ENTRY_AST_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CB_GL_ENTRY_AST_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CB_GL_ENTRY_AST_T
(
CB_GL_ACCT_ID NUMBER(12)
, CB_LN_NBR NUMBER(3)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CM_FDOC_NBR VARCHAR2(14)
, CONSTRAINT CB_GL_ENTRY_AST_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CB_GL_ENTRY_AST_T
ADD CONSTRAINT CB_GL_ENTRY_AST_TP1
PRIMARY KEY (CB_GL_ACCT_ID,CB_LN_NBR)
/
CREATE INDEX CB_GL_ENTRY_AST_TI1
ON CB_GL_ENTRY_AST_T
(CM_FDOC_NBR)
/
-----------------------------------------------------------------------------
-- CB_GL_ENTRY_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CB_GL_ENTRY_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CB_GL_ENTRY_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CB_GL_ENTRY_T
(
CB_GL_ACCT_ID NUMBER(12)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, UNIV_FISCAL_YR NUMBER(4) NOT NULL
, FIN_COA_CD VARCHAR2(2) NOT NULL
, ACCOUNT_NBR VARCHAR2(7) NOT NULL
, SUB_ACCT_NBR VARCHAR2(5) NOT NULL
, FIN_OBJECT_CD VARCHAR2(4) NOT NULL
, FIN_SUB_OBJ_CD VARCHAR2(3) NOT NULL
, FIN_BALANCE_TYP_CD VARCHAR2(2) NOT NULL
, FIN_OBJ_TYP_CD VARCHAR2(2) NOT NULL
, UNIV_FISCAL_PRD_CD VARCHAR2(2) NOT NULL
, FDOC_TYP_CD VARCHAR2(8) NOT NULL
, FS_ORIGIN_CD VARCHAR2(2) NOT NULL
, FDOC_NBR VARCHAR2(14) NOT NULL
, TRN_ENTR_SEQ_NBR NUMBER(5) NOT NULL
, TRN_LDGR_ENTR_DESC VARCHAR2(40)
, TRN_LDGR_ENTR_AMT NUMBER(19,2)
, ORG_REFERENCE_ID VARCHAR2(8)
, FS_REF_ORIGIN_CD VARCHAR2(2)
, FDOC_REF_NBR VARCHAR2(14)
, TRN_DEBIT_CRDT_CD VARCHAR2(1)
, TRANSACTION_DT DATE
, ORG_DOC_NBR VARCHAR2(10)
, PROJECT_CD VARCHAR2(10)
, TRN_POST_DT DATE
, TIMESTAMP DATE
, ACTV_IND VARCHAR2(1) NOT NULL
, TRN_LDGR_SUBMIT_AMT NUMBER(19,2)
)
/
ALTER TABLE CB_GL_ENTRY_T
ADD CONSTRAINT CB_GL_ENTRY_TP1
PRIMARY KEY (CB_GL_ACCT_ID)
/
CREATE INDEX CB_GL_ENTRY_TI1
ON CB_GL_ENTRY_T
(UNIV_FISCAL_YR, FIN_COA_CD, ACCOUNT_NBR, SUB_ACCT_NBR, FIN_OBJECT_CD, FIN_SUB_OBJ_CD, FIN_BALANCE_TYP_CD, FIN_OBJ_TYP_CD, UNIV_FISCAL_PRD_CD, FDOC_TYP_CD, FS_ORIGIN_CD, FDOC_NBR, TRN_ENTR_SEQ_NBR)
/
-----------------------------------------------------------------------------
-- CB_PRTG_DTL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CB_PRTG_DTL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CB_PRTG_DTL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CB_PRTG_DTL_T
(
PO_NUMBER VARCHAR2(9)
, ITM_LN_NBR NUMBER(3)
, CPTLAST_TAG_NBR VARCHAR2(8)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CPTLAST_SERIAL_NBR VARCHAR2(25)
, CPTLAST_ORGTAG_NBR VARCHAR2(8)
, CAMPUS_CD VARCHAR2(2)
, BLDG_CD VARCHAR2(10)
, BLDG_ROOM_NBR VARCHAR2(8)
, BLDG_SUB_ROOM_NBR VARCHAR2(2)
, AST_PRTGTAG_CRT_DT DATE
, CPTL_AST_GOV_TAG_NBR VARCHAR2(12)
, CPTL_AST_NTL_STOCK_NBR VARCHAR2(25)
, ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT CB_PRTG_DTL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CB_PRTG_DTL_T
ADD CONSTRAINT CB_PRTG_DTL_TP1
PRIMARY KEY (PO_NUMBER,ITM_LN_NBR,CPTLAST_TAG_NBR)
/
-----------------------------------------------------------------------------
-- CB_PRTG_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CB_PRTG_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CB_PRTG_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CB_PRTG_T
(
PO_NUMBER VARCHAR2(9)
, ITM_LN_NBR NUMBER(3)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CPTLAST_INV_QTY NUMBER(11,2)
, CPTLAST_TYP_CD VARCHAR2(7)
, CPTLAST_MFR_NM VARCHAR2(45)
, CPTLAST_MFRMDL_NBR VARCHAR2(25)
, VENDOR_NAME VARCHAR2(45)
, CPTLAST_TOPS_DESC VARCHAR2(4000)
, CPTLAST_ORG_TXT VARCHAR2(255)
, ORG_INVN_NM VARCHAR2(40)
, AST_REP_UNVL_ID VARCHAR2(40)
, FIN_COA_CD VARCHAR2(2)
, CM_PRTG_CRT_DT DATE
, ORG_CD VARCHAR2(4)
, ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT CB_PRTG_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CB_PRTG_T
ADD CONSTRAINT CB_PRTG_TP1
PRIMARY KEY (PO_NUMBER,ITM_LN_NBR)
/
-----------------------------------------------------------------------------
-- CB_PUR_ACTN_HIST_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CB_PUR_ACTN_HIST_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CB_PUR_ACTN_HIST_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CB_PUR_ACTN_HIST_T
(
ACTN_ID NUMBER(12)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ACTN_TYP_CD VARCHAR2(20)
, FRM_FDOC_NBR VARCHAR2(14) NOT NULL
, FRM_PUR_ITM_ID NUMBER(10) NOT NULL
, FRM_CB_LN_NBR NUMBER(3) NOT NULL
, TO_FDOC_NBR VARCHAR2(14) NOT NULL
, TO_PUR_ITM_ID NUMBER(10) NOT NULL
, TO_CB_LN_NBR NUMBER(3) NOT NULL
, CB_GL_ACCT_ID NUMBER(12)
, ITM_ACCT_TOT_AMT NUMBER(19,2)
, PUR_ITM_QTY NUMBER(11,2)
, ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT CB_PUR_ACTN_HIST_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CB_PUR_ACTN_HIST_T
ADD CONSTRAINT CB_PUR_ACTN_HIST_TP1
PRIMARY KEY (ACTN_ID)
/
-----------------------------------------------------------------------------
-- CB_PUR_DOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CB_PUR_DOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CB_PUR_DOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CB_PUR_DOC_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, PO_ITM_ID NUMBER(10)
, PO_ID NUMBER(9)
, ACTV_IND VARCHAR2(1) NOT NULL
, DOC_TYP_CD VARCHAR2(8) NOT NULL
, CONSTRAINT CB_PUR_DOC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CB_PUR_DOC_T
ADD CONSTRAINT CB_PUR_DOC_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- CB_PUR_ITM_AST_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CB_PUR_ITM_AST_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CB_PUR_ITM_AST_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CB_PUR_ITM_AST_T
(
FDOC_NBR VARCHAR2(14)
, PUR_ITM_ID NUMBER(10)
, CB_LN_NBR NUMBER(3)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, PUR_ITM_DESC VARCHAR2(4000)
, PUR_ITM_QTY NUMBER(11,2)
, CM_FDOC_NBR VARCHAR2(14)
, ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT CB_PUR_ITM_AST_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CB_PUR_ITM_AST_T
ADD CONSTRAINT CB_PUR_ITM_AST_TP1
PRIMARY KEY (FDOC_NBR,PUR_ITM_ID,CB_LN_NBR)
/
CREATE INDEX CB_PUR_ITM_AST_TI1
ON CB_PUR_ITM_AST_T
(FDOC_NBR, PUR_ITM_ID)
/
CREATE INDEX CB_PUR_ITM_AST_TI2
ON CB_PUR_ITM_AST_T
(CM_FDOC_NBR)
/
-----------------------------------------------------------------------------
-- CB_PUR_LN_AST_ACCT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CB_PUR_LN_AST_ACCT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CB_PUR_LN_AST_ACCT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CB_PUR_LN_AST_ACCT_T
(
FDOC_NBR VARCHAR2(14)
, PUR_ITM_ID NUMBER(10)
, CB_LN_NBR NUMBER(3)
, CB_GL_ACCT_ID NUMBER(12)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ITM_ACCT_TOT_AMT NUMBER(19,2)
, ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT CB_PUR_LN_AST_ACCT_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CB_PUR_LN_AST_ACCT_T
ADD CONSTRAINT CB_PUR_LN_AST_ACCT_TP1
PRIMARY KEY (FDOC_NBR,PUR_ITM_ID,CB_LN_NBR,CB_GL_ACCT_ID)
/
-----------------------------------------------------------------------------
-- CG_AGENCY_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CG_AGENCY_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CG_AGENCY_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CG_AGENCY_T
(
CG_AGENCY_NBR VARCHAR2(5)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CG_AGENCY_RPT_NM VARCHAR2(30)
, CG_AGENCY_FULL_NM VARCHAR2(50)
, CG_AGNCY_INDR_AMT NUMBER(19,2)
, CG_AGENCY_HIST_IND VARCHAR2(1)
, CG_AGNCY_IN_ST_IND VARCHAR2(1)
, CG_AGENCY_TYP_CD VARCHAR2(1)
, CG_RPTTO_AGNCY_NBR VARCHAR2(5)
, CONSTRAINT CG_AGENCY_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CG_AGENCY_T
ADD CONSTRAINT CG_AGENCY_TP1
PRIMARY KEY (CG_AGENCY_NBR)
/
CREATE INDEX CG_AGENCY_TI2
ON CG_AGENCY_T
(CG_RPTTO_AGNCY_NBR)
/
CREATE INDEX CG_AGENCY_TI3
ON CG_AGENCY_T
(CG_AGENCY_TYP_CD)
/
-----------------------------------------------------------------------------
-- CG_AGENCY_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CG_AGENCY_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CG_AGENCY_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CG_AGENCY_TYP_T
(
CG_AGENCY_TYP_CD VARCHAR2(1)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CG_AGENCY_TYP_DESC VARCHAR2(30)
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT CG_AGENCY_TYP_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CG_AGENCY_TYP_T
ADD CONSTRAINT CG_AGENCY_TYP_TP1
PRIMARY KEY (CG_AGENCY_TYP_CD)
/
-----------------------------------------------------------------------------
-- CG_AWD_ACCT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CG_AWD_ACCT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CG_AWD_ACCT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CG_AWD_ACCT_T
(
CGPRPSL_NBR NUMBER(12)
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, PERSON_UNVL_ID VARCHAR2(40)
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT CG_AWD_ACCT_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CG_AWD_ACCT_T
ADD CONSTRAINT CG_AWD_ACCT_TP1
PRIMARY KEY (CGPRPSL_NBR,FIN_COA_CD,ACCOUNT_NBR)
/
CREATE INDEX CG_AWD_ACCT_TI2
ON CG_AWD_ACCT_T
(FIN_COA_CD, ACCOUNT_NBR)
/
CREATE INDEX CG_AWD_ACCT_TI4
ON CG_AWD_ACCT_T
(PERSON_UNVL_ID)
/
-----------------------------------------------------------------------------
-- CG_AWD_ORG_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CG_AWD_ORG_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CG_AWD_ORG_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CG_AWD_ORG_T
(
FIN_COA_CD VARCHAR2(2)
, ORG_CD VARCHAR2(4)
, CGPRPSL_NBR NUMBER(12)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CGAWD_PRM_ORG_IND VARCHAR2(1)
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT CG_AWD_ORG_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CG_AWD_ORG_T
ADD CONSTRAINT CG_AWD_ORG_TP1
PRIMARY KEY (FIN_COA_CD,ORG_CD,CGPRPSL_NBR)
/
-----------------------------------------------------------------------------
-- CG_AWD_PRJDR_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CG_AWD_PRJDR_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CG_AWD_PRJDR_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CG_AWD_PRJDR_T
(
PERSON_UNVL_ID VARCHAR2(40)
, CGPRPSL_NBR NUMBER(12)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CGAWD_PRMPRJDR_IND VARCHAR2(1)
, CGAWD_PRJDRPRJ_TTL VARCHAR2(100)
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT CG_AWD_PRJDR_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CG_AWD_PRJDR_T
ADD CONSTRAINT CG_AWD_PRJDR_TP1
PRIMARY KEY (PERSON_UNVL_ID,CGPRPSL_NBR)
/
CREATE INDEX CG_AWD_PRJDR_TI2
ON CG_AWD_PRJDR_T
(CGPRPSL_NBR)
/
-----------------------------------------------------------------------------
-- CG_AWD_STAT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CG_AWD_STAT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CG_AWD_STAT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CG_AWD_STAT_T
(
CGAWD_STAT_CD VARCHAR2(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CGAWD_STAT_DESC VARCHAR2(15)
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT CG_AWD_STAT_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CG_AWD_STAT_T
ADD CONSTRAINT CG_AWD_STAT_TP1
PRIMARY KEY (CGAWD_STAT_CD)
/
-----------------------------------------------------------------------------
-- CG_AWD_SUBCN_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CG_AWD_SUBCN_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CG_AWD_SUBCN_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CG_AWD_SUBCN_T
(
AWD_SUBCN_AMND_NBR VARCHAR2(2)
, CGAWD_SUBCN_NBR VARCHAR2(2)
, CG_SUBCNR_NBR VARCHAR2(5)
, CGPRPSL_NBR NUMBER(12)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CG_SUBCN_AMT NUMBER(19,2)
, SUBCNR_CNTCT_F_NM VARCHAR2(20)
, SUBCNR_CNTCT_L_NM VARCHAR2(25)
, SUBCN_AUDTHIST_TXT VARCHAR2(2000)
, CGAWD_SUBCN_DESC VARCHAR2(30)
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT CG_AWD_SUBCN_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CG_AWD_SUBCN_T
ADD CONSTRAINT CG_AWD_SUBCN_TP1
PRIMARY KEY (AWD_SUBCN_AMND_NBR,CGAWD_SUBCN_NBR,CG_SUBCNR_NBR,CGPRPSL_NBR)
/
CREATE INDEX CG_AWD_SUBCN_TI2
ON CG_AWD_SUBCN_T
(CGPRPSL_NBR)
/
CREATE INDEX CG_AWD_SUBCN_TI3
ON CG_AWD_SUBCN_T
(CG_SUBCNR_NBR)
/
-----------------------------------------------------------------------------
-- CG_AWD_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CG_AWD_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CG_AWD_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CG_AWD_T
(
CGPRPSL_NBR NUMBER(12)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CGAWD_BEG_DT DATE
, CGAWD_END_DT DATE
, CGAWD_TOT_AMT NUMBER(19,2)
, CGAWD_ADDENDUM_NBR VARCHAR2(7)
, CGAWD_ALOC_UCS_AMT NUMBER(19,2)
, CG_AGENCY_AWD_NBR VARCHAR2(27)
, CG_FEDPT_FND_AMT NUMBER(19,2)
, CGAWD_ENTRY_DT DATE
, CG_AGENCY_FUT1_AMT NUMBER(19,2)
, CG_AGENCY_FUT2_AMT NUMBER(19,2)
, CG_AGENCY_FUT3_AMT NUMBER(19,2)
, CGAWD_DOC_NBR VARCHAR2(12)
, CGAWD_LST_UPDT_DT DATE
, CG_FEDPT_IND VARCHAR2(1)
, CG_OLD_PRPSL_NBR VARCHAR2(8)
, CGAWD_DRCT_CST_AMT NUMBER(19,2)
, CGAWD_INDR_CST_AMT NUMBER(19,2)
, CG_FED_FNDED_AMT NUMBER(19,2)
, CGAWD_CREATE_TS DATE
, CGAWD_CLOSING_DT DATE
, CGPRPSL_AWD_TYP_CD VARCHAR2(1)
, CGAWD_STAT_CD VARCHAR2(2)
, CG_LTRCR_FNDGRP_CD VARCHAR2(4)
, CG_GRANT_DESC_CD VARCHAR2(3)
, CG_AGENCY_NBR VARCHAR2(5)
, CG_FEDPT_AGNCY_NBR VARCHAR2(5)
, CG_AGNCY_ANALST_NM VARCHAR2(123)
, CG_ANALYST_PHN_NBR VARCHAR2(10)
, CGAWD_PROJ_TTL VARCHAR2(250)
, CGAWD_COMMENT_TXT VARCHAR2(250)
, CGAWD_PURPOSE_CD VARCHAR2(1)
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT CG_AWD_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CG_AWD_T
ADD CONSTRAINT CG_AWD_TP1
PRIMARY KEY (CGPRPSL_NBR)
/
CREATE INDEX CG_AWD_TI2
ON CG_AWD_T
(CG_AGENCY_NBR)
/
CREATE INDEX CG_AWD_TI3
ON CG_AWD_T
(CGAWD_STAT_CD)
/
CREATE INDEX CG_AWD_TI4
ON CG_AWD_T
(CG_FEDPT_AGNCY_NBR)
/
CREATE INDEX CG_AWD_TI5
ON CG_AWD_T
(CG_GRANT_DESC_CD)
/
CREATE INDEX CG_AWD_TI6
ON CG_AWD_T
(CG_LTRCR_FNDGRP_CD)
/
CREATE INDEX CG_AWD_TI7
ON CG_AWD_T
(CGPRPSL_AWD_TYP_CD)
/
CREATE INDEX CG_AWD_TI8
ON CG_AWD_T
(CGAWD_PURPOSE_CD)
/
-----------------------------------------------------------------------------
-- CG_GRANT_DESC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CG_GRANT_DESC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CG_GRANT_DESC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CG_GRANT_DESC_T
(
CG_GRANT_DESC_CD VARCHAR2(3)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CG_GRANT_DESC VARCHAR2(25)
, CG_GRNT_DESC_ACTV_CD VARCHAR2(1)
, CONSTRAINT CG_GRANT_DESC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CG_GRANT_DESC_T
ADD CONSTRAINT CG_GRANT_DESC_TP1
PRIMARY KEY (CG_GRANT_DESC_CD)
/
-----------------------------------------------------------------------------
-- CG_LTRCR_FNDGRP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CG_LTRCR_FNDGRP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CG_LTRCR_FNDGRP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CG_LTRCR_FNDGRP_T
(
CG_LTRCR_FNDGRP_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, LTRCR_FNDGRP_DESC VARCHAR2(40)
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT CG_LTRCR_FNDGRP_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CG_LTRCR_FNDGRP_T
ADD CONSTRAINT CG_LTRCR_FNDGRP_TP1
PRIMARY KEY (CG_LTRCR_FNDGRP_CD)
/
-----------------------------------------------------------------------------
-- CG_PRPSL_AWD_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CG_PRPSL_AWD_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CG_PRPSL_AWD_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CG_PRPSL_AWD_TYP_T
(
CGPRPSL_AWD_TYP_CD VARCHAR2(1)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, PRPSL_AWD_TYP_DESC VARCHAR2(20)
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT CG_PRPSL_AWD_TYP_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CG_PRPSL_AWD_TYP_T
ADD CONSTRAINT CG_PRPSL_AWD_TYP_TP1
PRIMARY KEY (CGPRPSL_AWD_TYP_CD)
/
-----------------------------------------------------------------------------
-- CG_PRPSL_CLOSE_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CG_PRPSL_CLOSE_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CG_PRPSL_CLOSE_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CG_PRPSL_CLOSE_T
(
CG_PRPSL_CLOSE_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CG_LAST_CLOSED_DT DATE
, CGAWD_CLOSED_CNT NUMBER(12)
, CGPRPSL_CLOSED_CNT NUMBER(12)
, PERSON_USER_ID VARCHAR2(40)
, CG_USR_INITIATE_DT DATE
, CONSTRAINT CG_PRPSL_CLOSE_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CG_PRPSL_CLOSE_T
ADD CONSTRAINT CG_PRPSL_CLOSE_TP1
PRIMARY KEY (CG_PRPSL_CLOSE_NBR)
/
-----------------------------------------------------------------------------
-- CG_PRPSL_ORG_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CG_PRPSL_ORG_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CG_PRPSL_ORG_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CG_PRPSL_ORG_T
(
FIN_COA_CD VARCHAR2(2)
, ORG_CD VARCHAR2(4)
, CGPRPSL_NBR NUMBER(12)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CGPRPSL_PRMORG_IND VARCHAR2(1)
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT CG_PRPSL_ORG_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CG_PRPSL_ORG_T
ADD CONSTRAINT CG_PRPSL_ORG_TP1
PRIMARY KEY (FIN_COA_CD,ORG_CD,CGPRPSL_NBR)
/
CREATE INDEX CG_PRPSL_ORG_TI2
ON CG_PRPSL_ORG_T
(CGPRPSL_NBR)
/
-----------------------------------------------------------------------------
-- CG_PRPSL_PRJDR_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CG_PRPSL_PRJDR_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CG_PRPSL_PRJDR_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CG_PRPSL_PRJDR_T
(
PERSON_UNVL_ID VARCHAR2(40)
, CGPRPSL_NBR NUMBER(12)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, PRPSL_PRMPRJDR_IND VARCHAR2(1)
, PRPSL_PRJDRPRJ_TTL VARCHAR2(100)
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT CG_PRPSL_PRJDR_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CG_PRPSL_PRJDR_T
ADD CONSTRAINT CG_PRPSL_PRJDR_TP1
PRIMARY KEY (PERSON_UNVL_ID,CGPRPSL_NBR)
/
CREATE INDEX CG_PRPSL_PRJDR_TI2
ON CG_PRPSL_PRJDR_T
(CGPRPSL_NBR)
/
-----------------------------------------------------------------------------
-- CG_PRPSL_PURPOSE_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CG_PRPSL_PURPOSE_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CG_PRPSL_PURPOSE_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CG_PRPSL_PURPOSE_T
(
CGPRPSL_PURPOSE_CD VARCHAR2(1)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, PRPSL_PURPOSE_DESC VARCHAR2(26)
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT CG_PRPSL_PURPOSE_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CG_PRPSL_PURPOSE_T
ADD CONSTRAINT CG_PRPSL_PURPOSE_TP1
PRIMARY KEY (CGPRPSL_PURPOSE_CD)
/
-----------------------------------------------------------------------------
-- CG_PRPSL_RSRCH_RSK_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CG_PRPSL_RSRCH_RSK_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CG_PRPSL_RSRCH_RSK_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CG_PRPSL_RSRCH_RSK_T
(
CGPRPSL_NBR NUMBER(12)
, RSRCH_RSK_TYP_CD VARCHAR2(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, RSRCH_RSK_TYP_IND VARCHAR2(1) NOT NULL
, CONSTRAINT CG_PRPSL_RSRCH_RSK_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CG_PRPSL_RSRCH_RSK_T
ADD CONSTRAINT CG_PRPSL_RSRCH_RSK_TP1
PRIMARY KEY (CGPRPSL_NBR,RSRCH_RSK_TYP_CD)
/
-----------------------------------------------------------------------------
-- CG_PRPSL_STAT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CG_PRPSL_STAT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CG_PRPSL_STAT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CG_PRPSL_STAT_T
(
CGPRPSL_STAT_CD VARCHAR2(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CGPRPSL_STAT_DESC VARCHAR2(15)
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT CG_PRPSL_STAT_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CG_PRPSL_STAT_T
ADD CONSTRAINT CG_PRPSL_STAT_TP1
PRIMARY KEY (CGPRPSL_STAT_CD)
/
-----------------------------------------------------------------------------
-- CG_PRPSL_SUBCN_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CG_PRPSL_SUBCN_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CG_PRPSL_SUBCN_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CG_PRPSL_SUBCN_T
(
CGPRPSL_SUBCN_NBR VARCHAR2(2)
, CGPRPSL_NBR NUMBER(12)
, CG_SUBCNR_NBR VARCHAR2(5)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CGPRPSL_SUBCN_AMT NUMBER(19,2)
, CGPRPSL_SUBCN_DESC VARCHAR2(30)
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT CG_PRPSL_SUBCN_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CG_PRPSL_SUBCN_T
ADD CONSTRAINT CG_PRPSL_SUBCN_TP1
PRIMARY KEY (CGPRPSL_SUBCN_NBR,CGPRPSL_NBR,CG_SUBCNR_NBR)
/
CREATE INDEX CG_PRPSL_SUBCN_TI2
ON CG_PRPSL_SUBCN_T
(CGPRPSL_NBR)
/
CREATE INDEX CG_PRPSL_SUBCN_TI3
ON CG_PRPSL_SUBCN_T
(CG_SUBCNR_NBR)
/
-----------------------------------------------------------------------------
-- CG_PRPSL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CG_PRPSL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CG_PRPSL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CG_PRPSL_T
(
CGPRPSL_NBR NUMBER(12)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CGPRPSL_BEG_DT DATE
, CGPRPSL_END_DT DATE
, CGPRPSL_TOT_AMT NUMBER(19,2)
, CGPRPSL_DRCTCS_AMT NUMBER(19,2)
, CGPRPSL_INDRCS_AMT NUMBER(19,2)
, CGPRPSL_REJECTD_DT DATE
, CGPRPSL_LSTUPDT_DT DATE
, CGPRPSL_DUE_DT DATE
, CGPRPSL_TOTPRJ_AMT NUMBER(19,2)
, CGPRPSL_SUBMSSN_DT DATE
, CGPRPSL_FEDPT_IND VARCHAR2(1)
, CG_OLD_PRPSL_NBR VARCHAR2(8)
, CG_GRANT_NBR VARCHAR2(27)
, CGPRPSL_CLOSING_DT DATE
, CGPRPSL_AWD_TYP_CD VARCHAR2(1)
, CG_AGENCY_NBR VARCHAR2(5)
, CGPRPSL_STAT_CD VARCHAR2(2)
, CG_FEDPT_AGNCY_NBR VARCHAR2(5)
, CG_CFDA_NBR VARCHAR2(6)
, CGPRPSL_FELLOW_NM VARCHAR2(123)
, CGPRPSL_PURPOSE_CD VARCHAR2(1)
, CGPRPSL_PROJ_TTL VARCHAR2(250)
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT CG_PRPSL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CG_PRPSL_T
ADD CONSTRAINT CG_PRPSL_TP1
PRIMARY KEY (CGPRPSL_NBR)
/
CREATE INDEX CG_PRPSL_TI2
ON CG_PRPSL_T
(CG_AGENCY_NBR)
/
CREATE INDEX CG_PRPSL_TI3
ON CG_PRPSL_T
(CGPRPSL_AWD_TYP_CD)
/
CREATE INDEX CG_PRPSL_TI4
ON CG_PRPSL_T
(CGPRPSL_PURPOSE_CD)
/
CREATE INDEX CG_PRPSL_TI5
ON CG_PRPSL_T
(CGPRPSL_STAT_CD)
/
CREATE INDEX CG_PRPSL_TI6
ON CG_PRPSL_T
(CG_FEDPT_AGNCY_NBR)
/
-----------------------------------------------------------------------------
-- CG_SUBCNR_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CG_SUBCNR_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CG_SUBCNR_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CG_SUBCNR_T
(
CG_SUBCNR_NBR VARCHAR2(5)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CG_SUBCNR_NM VARCHAR2(123)
, CG_SUBCNR_LN1_ADDR VARCHAR2(25)
, CG_SUBCNR_LN2_ADDR VARCHAR2(20)
, CG_SUBCNR_CITY_NM VARCHAR2(20)
, CG_SUBCNR_ST_CD VARCHAR2(2)
, CG_SUBCNR_ZIP_CD VARCHAR2(20)
, CGSUBCNR_CNTRY_CD VARCHAR2(2)
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT CG_SUBCNR_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CG_SUBCNR_T
ADD CONSTRAINT CG_SUBCNR_TP1
PRIMARY KEY (CG_SUBCNR_NBR)
/
-----------------------------------------------------------------------------
-- CM_ACQ_TYPE_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CM_ACQ_TYPE_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CM_ACQ_TYPE_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CM_ACQ_TYPE_T
(
CPTLAST_ACQ_TYP_CD VARCHAR2(1)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CPTLAST_ACQ_TYP_NM VARCHAR2(40)
, CPTLAST_INC_OBJ_CD VARCHAR2(4)
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT CM_ACQ_TYPE_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CM_ACQ_TYPE_T
ADD CONSTRAINT CM_ACQ_TYPE_TP1
PRIMARY KEY (CPTLAST_ACQ_TYP_CD)
/
-----------------------------------------------------------------------------
-- CM_ASSET_TYPE_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CM_ASSET_TYPE_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CM_ASSET_TYPE_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CM_ASSET_TYPE_T
(
CPTLAST_TYP_CD VARCHAR2(7)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CPTLAST_TYP_DESC VARCHAR2(70)
, CPTLAST_DEPRLF_LMT NUMBER(5)
, CPTLAST_MOVING_CD VARCHAR2(1)
, CPTLAST_RQDBLDG_CD VARCHAR2(1)
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT CM_ASSET_TYPE_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CM_ASSET_TYPE_T
ADD CONSTRAINT CM_ASSET_TYPE_TP1
PRIMARY KEY (CPTLAST_TYP_CD)
/
-----------------------------------------------------------------------------
-- CM_AST_COMPONENT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CM_AST_COMPONENT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CM_AST_COMPONENT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CM_AST_COMPONENT_T
(
CPTLAST_NBR NUMBER(12)
, CACMP_NBR NUMBER(5)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CACMP_DESC VARCHAR2(255)
, CACMP_CNTCTPHN_NBR VARCHAR2(10)
, CACMP_COND_CD VARCHAR2(1)
, CACMP_EST_LFTM_LMT NUMBER(5)
, CACMP_MFR_NM VARCHAR2(45)
, CACMP_MFR_MDL_NBR VARCHAR2(25)
, CACMP_SERIAL_NBR VARCHAR2(25)
, CACMP_ORG_TAG_NBR VARCHAR2(8)
, CACMP_ORG_TXT VARCHAR2(255)
, CACMP_REPLACE_AMT NUMBER(19,2)
, CACMP_VENDOR_NM VARCHAR2(45)
, CACMP_WRNTY_NBR VARCHAR2(25)
, CACMP_WRNTYPHN_NBR VARCHAR2(13)
, CACMP_WRNTYCNTC_NM VARCHAR2(123)
, CACMP_WRNTY_PO_NBR VARCHAR2(9)
, CACMP_WRNTY_BEG_DT DATE
, CACMP_WRNTY_END_DT DATE
, CACMP_WRNTY_TXT VARCHAR2(40)
, CPTL_AST_GOV_TAG_NBR VARCHAR2(12)
, CPTL_AST_NTL_STOCK_NBR VARCHAR2(25)
, ACTV_IND VARCHAR2(1) default 'Y'
, CONSTRAINT CM_AST_COMPONENT_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CM_AST_COMPONENT_T
ADD CONSTRAINT CM_AST_COMPONENT_TP1
PRIMARY KEY (CPTLAST_NBR,CACMP_NBR)
/
CREATE INDEX CM_AST_COMPONENT_TI2
ON CM_AST_COMPONENT_T
(CACMP_COND_CD)
/
-----------------------------------------------------------------------------
-- CM_AST_CONDITION_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CM_AST_CONDITION_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CM_AST_CONDITION_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CM_AST_CONDITION_T
(
CPTLAST_COND_CD VARCHAR2(1)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CPTLAST_COND_NM VARCHAR2(40)
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT CM_AST_CONDITION_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CM_AST_CONDITION_T
ADD CONSTRAINT CM_AST_CONDITION_TP1
PRIMARY KEY (CPTLAST_COND_CD)
/
-----------------------------------------------------------------------------
-- CM_AST_DEPR_CNVNTN_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CM_AST_DEPR_CNVNTN_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CM_AST_DEPR_CNVNTN_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CM_AST_DEPR_CNVNTN_T
(
FIN_OBJ_SUB_TYPE_CD VARCHAR2(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CPTL_AST_DEPR_CNVNTN_CD VARCHAR2(2)
, ACTV_IND VARCHAR2(1)
, CONSTRAINT CM_AST_DEPR_CNVNTN_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CM_AST_DEPR_CNVNTN_T
ADD CONSTRAINT CM_AST_DEPR_CNVNTN_TP1
PRIMARY KEY (FIN_OBJ_SUB_TYPE_CD)
/
-----------------------------------------------------------------------------
-- CM_AST_DEPR_MTHD_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CM_AST_DEPR_MTHD_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CM_AST_DEPR_MTHD_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CM_AST_DEPR_MTHD_T
(
AST_DEPR_METHOD_CD VARCHAR2(3)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, AST_DEPR_METHOD_NM VARCHAR2(40)
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT CM_AST_DEPR_MTHD_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CM_AST_DEPR_MTHD_T
ADD CONSTRAINT CM_AST_DEPR_MTHD_TP1
PRIMARY KEY (AST_DEPR_METHOD_CD)
/
-----------------------------------------------------------------------------
-- CM_AST_LOC_DOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CM_AST_LOC_DOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CM_AST_LOC_DOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CM_AST_LOC_DOC_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CONSTRAINT CM_AST_LOC_DOC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CM_AST_LOC_DOC_T
ADD CONSTRAINT CM_AST_LOC_DOC_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- CM_AST_LOC_DTL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CM_AST_LOC_DTL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CM_AST_LOC_DTL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CM_AST_LOC_DTL_T
(
FDOC_NBR VARCHAR2(14)
, CPTLAST_NBR NUMBER(12)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CAMPUS_CD VARCHAR2(2)
, BLDG_CD VARCHAR2(10)
, BLDG_ROOM_NBR VARCHAR2(8)
, BLDG_SUB_ROOM_NBR VARCHAR2(2)
, CPTLAST_TAG_NBR VARCHAR2(8)
, CONSTRAINT CM_AST_LOC_DTL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CM_AST_LOC_DTL_T
ADD CONSTRAINT CM_AST_LOC_DTL_TP1
PRIMARY KEY (FDOC_NBR,CPTLAST_NBR)
/
-----------------------------------------------------------------------------
-- CM_AST_LOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CM_AST_LOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CM_AST_LOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CM_AST_LOC_T
(
CPTLAST_NBR NUMBER(12)
, AST_LOC_TYP_CD VARCHAR2(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, AST_LOC_CNTCT_NM VARCHAR2(123)
, AST_LOC_CNTCT_ID VARCHAR2(40)
, AST_LOC_INST_NM VARCHAR2(50)
, AST_LOC_PHN_NBR VARCHAR2(13)
, AST_LOC_STRT_ADDR VARCHAR2(50)
, AST_LOC_CITY_NM VARCHAR2(50)
, AST_LOC_STATE_CD VARCHAR2(2)
, AST_LOC_CNTRY_CD VARCHAR2(2)
, AST_LOC_ZIP_CD VARCHAR2(20)
, CONSTRAINT CM_AST_LOC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CM_AST_LOC_T
ADD CONSTRAINT CM_AST_LOC_TP1
PRIMARY KEY (CPTLAST_NBR,AST_LOC_TYP_CD)
/
-----------------------------------------------------------------------------
-- CM_AST_LOC_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CM_AST_LOC_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CM_AST_LOC_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CM_AST_LOC_TYP_T
(
CPTLAST_LOC_TYP_CD VARCHAR2(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CPTLAST_LOC_TYP_NM VARCHAR2(30)
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT CM_AST_LOC_TYP_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CM_AST_LOC_TYP_T
ADD CONSTRAINT CM_AST_LOC_TYP_TP1
PRIMARY KEY (CPTLAST_LOC_TYP_CD)
/
-----------------------------------------------------------------------------
-- CM_AST_ORG_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CM_AST_ORG_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CM_AST_ORG_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CM_AST_ORG_T
(
CPTLAST_NBR NUMBER(12)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ORG_CPTLAST_TYP_ID VARCHAR2(20)
, CPTLAST_ORGTAG_NBR VARCHAR2(8)
, ORG_TXT VARCHAR2(255)
, CONSTRAINT CM_AST_ORG_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CM_AST_ORG_T
ADD CONSTRAINT CM_AST_ORG_TP1
PRIMARY KEY (CPTLAST_NBR)
/
-----------------------------------------------------------------------------
-- CM_AST_PAYMENT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CM_AST_PAYMENT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CM_AST_PAYMENT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CM_AST_PAYMENT_T
(
CPTLAST_NBR NUMBER(12)
, AST_PMT_SEQ_NBR NUMBER(12)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_OBJECT_CD VARCHAR2(4)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, FS_ORIGIN_CD VARCHAR2(2)
, FDOC_TYP_CD VARCHAR2(8)
, FDOC_NBR VARCHAR2(14)
, FDOC_POST_YR NUMBER(4)
, FDOC_POST_PRD_CD VARCHAR2(2)
, FDOC_POST_DT DATE
, PROJECT_CD VARCHAR2(10)
, ORG_REFERENCE_ID VARCHAR2(8)
, ACCT_CHARGE_AMT NUMBER(19,2)
, PO_NUMBER VARCHAR2(9)
, REQUISITION_NBR VARCHAR2(8)
, AST_DEPR1_BASE_AMT NUMBER(19,2)
, AST_ACUM_DEPR1_AMT NUMBER(19,2)
, AST_PRVYRDEPR1_AMT NUMBER(19,2)
, AST_PRD1_DEPR1_AMT NUMBER(19,2)
, AST_PRD2_DEPR1_AMT NUMBER(19,2)
, AST_PRD3_DEPR1_AMT NUMBER(19,2)
, AST_PRD4_DEPR1_AMT NUMBER(19,2)
, AST_PRD5_DEPR1_AMT NUMBER(19,2)
, AST_PRD6_DEPR1_AMT NUMBER(19,2)
, AST_PRD7_DEPR1_AMT NUMBER(19,2)
, AST_PRD8_DEPR1_AMT NUMBER(19,2)
, AST_PRD9_DEPR1_AMT NUMBER(19,2)
, AST_PRD10DEPR1_AMT NUMBER(19,2)
, AST_PRD11DEPR1_AMT NUMBER(19,2)
, AST_PRD12DEPR1_AMT NUMBER(19,2)
, AST_TRNFR_PMT_CD VARCHAR2(1)
, CONSTRAINT CM_AST_PAYMENT_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CM_AST_PAYMENT_T
ADD CONSTRAINT CM_AST_PAYMENT_TP1
PRIMARY KEY (CPTLAST_NBR,AST_PMT_SEQ_NBR)
/
CREATE INDEX CM_AST_PAYMENT_TI2
ON CM_AST_PAYMENT_T
(PO_NUMBER)
/
-----------------------------------------------------------------------------
-- CM_AST_PMT_AST_DTL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CM_AST_PMT_AST_DTL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CM_AST_PMT_AST_DTL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CM_AST_PMT_AST_DTL_T
(
FDOC_NBR VARCHAR2(14)
, CPTLAST_NBR NUMBER(12)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CPTLAST_PREV_TOT_CST_AMT NUMBER(19,2)
, CPTLAST_ALLOC_AMT NUMBER(19,2) default 0 NOT NULL
, CPTLAST_ALLOC_VAL NUMBER(19,2) NOT NULL
, CPTLAST_ALLOC_VAL_PCT NUMBER(19,6)
, CONSTRAINT CM_AST_PMT_AST_DTL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CM_AST_PMT_AST_DTL_T
ADD CONSTRAINT CM_AST_PMT_AST_DTL_TP1
PRIMARY KEY (FDOC_NBR,CPTLAST_NBR)
/
-----------------------------------------------------------------------------
-- CM_AST_PMT_DOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CM_AST_PMT_DOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CM_AST_PMT_DOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CM_AST_PMT_DOC_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, NXT_AST_PMT_LN_NBR NUMBER(7)
, CB_ORIGIN_IND VARCHAR2(1)
, AST_PMT_DST_CD VARCHAR2(2) default '2' NOT NULL
, AST_PMT_DIST_CD_FROM_FP_IND VARCHAR2(1)
, CONSTRAINT CM_AST_PMT_DOC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CM_AST_PMT_DOC_T
ADD CONSTRAINT CM_AST_PMT_DOC_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- CM_AST_PMT_DOC_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CM_AST_PMT_DOC_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CM_AST_PMT_DOC_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CM_AST_PMT_DOC_TYP_T
(
DOC_TYP_ID NUMBER(7)
, VER_NBR NUMBER(8) default 1 NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
, DOC_TYP_NM VARCHAR2(8)
, ACTV_IND VARCHAR2(1) default 'Y'
, CONSTRAINT CM_AST_PMT_DOC_TYP_T_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CM_AST_PMT_DOC_TYP_T
ADD CONSTRAINT CM_AST_PMT_DOC_TYP_TP1
PRIMARY KEY (DOC_TYP_ID)
/
-----------------------------------------------------------------------------
-- CM_AST_PMT_DST_CD_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CM_AST_PMT_DST_CD_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CM_AST_PMT_DST_CD_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CM_AST_PMT_DST_CD_T
(
AST_PMT_DST_CD VARCHAR2(1)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) NOT NULL
, AST_PMT_DST_NM VARCHAR2(40) NOT NULL
, AST_PMT_DST_COL_NM VARCHAR2(40) NOT NULL
, AST_PMT_DST_EDT VARCHAR2(1) NOT NULL
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
)
/
ALTER TABLE CM_AST_PMT_DST_CD_T
ADD CONSTRAINT CM_AST_PMT_DST_CD_TP1
PRIMARY KEY (AST_PMT_DST_CD)
/
-----------------------------------------------------------------------------
-- CM_AST_PMT_DTL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CM_AST_PMT_DTL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CM_AST_PMT_DTL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CM_AST_PMT_DTL_T
(
FDOC_NBR VARCHAR2(14)
, FDOC_LINE_NBR NUMBER(7)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_POST_YR NUMBER(4)
, FDOC_POST_PRD_CD VARCHAR2(2)
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_OBJECT_CD VARCHAR2(4)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, PROJECT_CD VARCHAR2(10)
, ORG_REFERENCE_ID VARCHAR2(8)
, ACCT_CHARGE_AMT NUMBER(19,2)
, EXPND_FS_ORIGIN_CD VARCHAR2(2)
, EXPND_FDOC_NBR VARCHAR2(14)
, EXPND_FDOC_TYP_CD VARCHAR2(8)
, EXPND_FDOC_POST_DT DATE
, PO_NUMBER VARCHAR2(9)
, REQUISITION_NBR VARCHAR2(8)
, FDOC_OVERRIDE_CD VARCHAR2(100)
, AST_TRNFR_PMT_CD VARCHAR2(1)
, CONSTRAINT CM_AST_PMT_DTL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CM_AST_PMT_DTL_T
ADD CONSTRAINT CM_AST_PMT_DTL_TP1
PRIMARY KEY (FDOC_NBR,FDOC_LINE_NBR)
/
CREATE INDEX CM_AST_PMT_DTL_TI2
ON CM_AST_PMT_DTL_T
(FIN_COA_CD, ACCOUNT_NBR)
/
CREATE INDEX CM_AST_PMT_DTL_TI3
ON CM_AST_PMT_DTL_T
(FDOC_POST_YR, FIN_COA_CD, FIN_OBJECT_CD)
/
-----------------------------------------------------------------------------
-- CM_AST_RETIRE_DOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CM_AST_RETIRE_DOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CM_AST_RETIRE_DOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CM_AST_RETIRE_DOC_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, MERGED_TGT_CPTLAST_NBR NUMBER(12)
, AST_RETIRE_REAS_CD VARCHAR2(1)
, CPTLAST_RETIRE_DT DATE
, MERGED_TGT_CPTLAST_DESC VARCHAR2(4000)
, AST_RETIR_COA_CD VARCHAR2(2)
, AST_RETIR_ACCT_NBR VARCHAR2(7)
, AST_RETIR_CNTCT_NM VARCHAR2(123)
, AST_RETIR_INST_NM VARCHAR2(50)
, AST_RETIRSTRT_ADDR VARCHAR2(50)
, AST_RETIR_CITY_NM VARCHAR2(50)
, AST_RETIR_STATE_CD VARCHAR2(2)
, AST_RETIR_ZIP_CD VARCHAR2(20)
, AST_RETIR_CNTRY_CD VARCHAR2(2)
, AST_RETIR_PHN_NBR VARCHAR2(13)
, AST_EST_SELL_PRC NUMBER(19,2)
, CPTLAST_SALE_PRC NUMBER(19,2)
, CASH_RCPT_FDOC_NBR VARCHAR2(14)
, AST_HANDLG_FEE_AMT NUMBER(19,2)
, AST_PRVNTMAINT_AMT NUMBER(19,2)
, CPTLAST_BUYER_DESC VARCHAR2(25)
, AST_PD_CASE_NBR VARCHAR2(14)
, CONSTRAINT CM_AST_RETIRE_DOC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CM_AST_RETIRE_DOC_T
ADD CONSTRAINT CM_AST_RETIRE_DOC_TP1
PRIMARY KEY (FDOC_NBR)
/
CREATE INDEX CM_AST_RETIRE_DOC_TI2
ON CM_AST_RETIRE_DOC_T
(AST_RETIRE_REAS_CD)
/
-----------------------------------------------------------------------------
-- CM_AST_RETIRE_DTL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CM_AST_RETIRE_DTL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CM_AST_RETIRE_DTL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CM_AST_RETIRE_DTL_T
(
FDOC_NBR VARCHAR2(14)
, CPTLAST_NBR NUMBER(12)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CONSTRAINT CM_AST_RETIRE_DTL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CM_AST_RETIRE_DTL_T
ADD CONSTRAINT CM_AST_RETIRE_DTL_TP1
PRIMARY KEY (FDOC_NBR,CPTLAST_NBR)
/
-----------------------------------------------------------------------------
-- CM_AST_RPR_HIST_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CM_AST_RPR_HIST_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CM_AST_RPR_HIST_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CM_AST_RPR_HIST_T
(
CPTLAST_NBR NUMBER(12)
, CPTLAST_INCIDNT_DT DATE
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CPTLAST_PRBLM_DESC VARCHAR2(255)
, CPTLAST_RPRCNTC_NM VARCHAR2(123)
, CPTLAST_RPR_NT_TXT VARCHAR2(255)
, CPTLAST_EST_RPR_DT DATE
, CPTLAST_RPR_DT DATE
, CPTLAST_RPR_AMT NUMBER(19,2)
, AST_RPR_SOLN_DESC VARCHAR2(255)
, ACTV_IND VARCHAR2(1) default 'Y'
, CONSTRAINT CM_AST_RPR_HIST_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CM_AST_RPR_HIST_T
ADD CONSTRAINT CM_AST_RPR_HIST_TP1
PRIMARY KEY (CPTLAST_NBR,CPTLAST_INCIDNT_DT)
/
-----------------------------------------------------------------------------
-- CM_AST_STATUS_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CM_AST_STATUS_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CM_AST_STATUS_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CM_AST_STATUS_T
(
AST_INVN_STAT_CD VARCHAR2(1)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, AST_INVN_STAT_NM VARCHAR2(40)
, ROW_ACTV_IND VARCHAR2(1) default 'Y'
, CONSTRAINT CM_AST_STATUS_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CM_AST_STATUS_T
ADD CONSTRAINT CM_AST_STATUS_TP1
PRIMARY KEY (AST_INVN_STAT_CD)
/
-----------------------------------------------------------------------------
-- CM_AST_TRNFR_DOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CM_AST_TRNFR_DOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CM_AST_TRNFR_DOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CM_AST_TRNFR_DOC_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, AST_REP_UNVL_ID VARCHAR2(40)
, CAMPUS_CD VARCHAR2(2)
, BLDG_CD VARCHAR2(10)
, BLDG_ROOM_NBR VARCHAR2(8)
, BLDG_SUB_ROOM_NBR VARCHAR2(2)
, CPTLAST_ORGTAG_NBR VARCHAR2(8)
, ORG_OWNER_COA_CD VARCHAR2(2)
, ORG_OWNER_ACCT_NBR VARCHAR2(7)
, ORG_TXT VARCHAR2(255)
, ORG_INVN_NM VARCHAR2(40)
, TRNFR_FND_FDOC_NBR VARCHAR2(14)
, AST_OFFCMP_ADDR VARCHAR2(45)
, AST_OFFCMP_CITY_NM VARCHAR2(25)
, AST_OFFCMP_ST_CD VARCHAR2(2)
, AST_OFFCMP_ZIP_CD VARCHAR2(20)
, AST_INTRDPTSALE_CD CHAR(1)
, CPTLAST_NBR NUMBER(12)
, OLD_ORG_OWNER_COA_CD VARCHAR2(2)
, OLD_ORG_OWNER_ACCT_NBR VARCHAR2(7)
, AST_OFFCMP_NM VARCHAR2(123)
, AST_OFFCMP_CNTRY_CD VARCHAR2(2)
, CONSTRAINT CM_AST_TRNFR_DOC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CM_AST_TRNFR_DOC_T
ADD CONSTRAINT CM_AST_TRNFR_DOC_TP1
PRIMARY KEY (FDOC_NBR)
/
CREATE INDEX CM_AST_TRNFR_DOC_TI2
ON CM_AST_TRNFR_DOC_T
(AST_REP_UNVL_ID)
/
-----------------------------------------------------------------------------
-- CM_AST_WRNTY_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CM_AST_WRNTY_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CM_AST_WRNTY_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CM_AST_WRNTY_T
(
CPTLAST_NBR NUMBER(12)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, AST_WRNTY_CNTCT_NM VARCHAR2(123)
, AST_WRNTYPHN_NBR VARCHAR2(13)
, AST_WRNTY_BEG_DT DATE
, AST_WRNTY_END_DT DATE
, AST_WRNTY_NBR VARCHAR2(25)
, AST_WRNTY_PO_NBR VARCHAR2(9)
, AST_WRNTY_TXT VARCHAR2(40)
, ACTV_IND VARCHAR2(1) default 'Y'
, CONSTRAINT CM_AST_WRNTY_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CM_AST_WRNTY_T
ADD CONSTRAINT CM_AST_WRNTY_TP1
PRIMARY KEY (CPTLAST_NBR)
/
-----------------------------------------------------------------------------
-- CM_CPTLAST_DOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CM_CPTLAST_DOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CM_CPTLAST_DOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CM_CPTLAST_DOC_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_NXT_LINE_NBR NUMBER(7)
, CPTLAST_ACQ_TYP_CD VARCHAR2(1)
, CPTLAST_DESC VARCHAR2(4000)
, AST_INVN_STAT_CD VARCHAR2(1)
, CPTLAST_COND_CD VARCHAR2(1)
, CPTLAST_TYP_CD VARCHAR2(7)
, CPTLAST_MFR_NM VARCHAR2(45)
, CPTLAST_MFRMDL_NBR VARCHAR2(25)
, CPTLAST_TOTCST_AMT NUMBER(19,2)
, CPTL_AST_LAND_CNTY_NM VARCHAR2(20)
, CPTL_AST_LAND_ACRG_SZ NUMBER(7)
, CPTL_AST_LAND_PRCL_NBR VARCHAR2(30)
, CPTLAST_VENDOR_NM VARCHAR2(45)
, ORG_TXT VARCHAR2(255)
, CPTLAST_CRT_DT DATE
, CPTL_AST_IN_SRVC_DT DATE
, CPTL_AST_DEPR_DT DATE
, AST_REP_UNVL_ID VARCHAR2(40)
, ORG_OWNER_COA_CD VARCHAR2(2)
, ORG_OWNER_ACCT_NBR VARCHAR2(7)
, CG_AGENCY_NBR VARCHAR2(5)
, FDOC_TYP_CD VARCHAR2(8)
, SEP_SRC_CPTLAST_NBR NUMBER(12)
, SEP_SRC_AST_PMT_SEQ_NBR NUMBER(12)
, CB_ORIGIN_IND VARCHAR2(1)
, CONSTRAINT CM_CPTLAST_DOC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CM_CPTLAST_DOC_T
ADD CONSTRAINT CM_CPTLAST_DOC_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- CM_CPTLAST_DTL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CM_CPTLAST_DTL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CM_CPTLAST_DTL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CM_CPTLAST_DTL_T
(
FDOC_NBR VARCHAR2(14)
, CPTLAST_NBR NUMBER(12)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CAMPUS_CD VARCHAR2(2)
, BLDG_CD VARCHAR2(10)
, CPTLAST_SERIAL_NBR VARCHAR2(25)
, BLDG_ROOM_NBR VARCHAR2(8)
, BLDG_SUB_ROOM_NBR VARCHAR2(2)
, CPTLAST_TAG_NBR VARCHAR2(8)
, ORG_INVN_NM VARCHAR2(40)
, ORG_CPTLAST_TYP_ID VARCHAR2(20)
, AST_OFFCMP_NM VARCHAR2(123)
, AST_OFFCMP_ADDR VARCHAR2(45)
, AST_OFFCMP_CITY_NM VARCHAR2(45)
, AST_OFFCMP_ST_CD VARCHAR2(2)
, AST_OFFCMP_ZIP_CD VARCHAR2(20)
, AST_OFFCMP_CNTRY_CD VARCHAR2(2)
, CPTL_AST_GOV_TAG_NBR VARCHAR2(12)
, CPTL_AST_NTL_STOCK_NBR VARCHAR2(25)
, AST_REP_UNVL_ID VARCHAR2(40)
, CPTLAST_TYP_CD VARCHAR2(7)
, CPTLAST_DESC VARCHAR2(4000)
, CPTLAST_MFR_NM VARCHAR2(45)
, ORG_TXT VARCHAR2(255)
, CPTLAST_MFRMDL_NBR VARCHAR2(25)
, SEP_SRC_AMT NUMBER(19,2)
, CONSTRAINT CM_CPTLAST_DTL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CM_CPTLAST_DTL_T
ADD CONSTRAINT CM_CPTLAST_DTL_TP1
PRIMARY KEY (FDOC_NBR,CPTLAST_NBR)
/
-----------------------------------------------------------------------------
-- CM_CPTLAST_LOCK_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CM_CPTLAST_LOCK_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CM_CPTLAST_LOCK_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CM_CPTLAST_LOCK_T
(
DOC_HDR_ID VARCHAR2(14)
, CPTLAST_NBR NUMBER(12)
, LOCK_INFO_TXT VARCHAR2(20)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, DOC_TYP_NM VARCHAR2(10)
, CONSTRAINT CM_CPTLAST_LOCK_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CM_CPTLAST_LOCK_T
ADD CONSTRAINT CM_CPTLAST_LOCK_TP1
PRIMARY KEY (DOC_HDR_ID,CPTLAST_NBR,LOCK_INFO_TXT)
/
-----------------------------------------------------------------------------
-- CM_CPTLAST_OBJ_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CM_CPTLAST_OBJ_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CM_CPTLAST_OBJ_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CM_CPTLAST_OBJ_T
(
UNIV_FISCAL_YR NUMBER(4)
, FIN_COA_CD VARCHAR2(2)
, FIN_OBJ_SUB_TYPE_CD VARCHAR2(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CPTLZTN_FOBJ_CD VARCHAR2(4)
, ACCUM_DEPR_FOBJ_CD VARCHAR2(4)
, DEPR_EXP_FOBJ_CD VARCHAR2(4)
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT CM_CPTLAST_OBJ_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CM_CPTLAST_OBJ_T
ADD CONSTRAINT CM_CPTLAST_OBJ_TP1
PRIMARY KEY (UNIV_FISCAL_YR,FIN_COA_CD,FIN_OBJ_SUB_TYPE_CD)
/
CREATE INDEX CM_CPTLAST_OBJ_TI2
ON CM_CPTLAST_OBJ_T
(UNIV_FISCAL_YR, FIN_COA_CD, CPTLZTN_FOBJ_CD)
/
CREATE INDEX CM_CPTLAST_OBJ_TI3
ON CM_CPTLAST_OBJ_T
(UNIV_FISCAL_YR, FIN_COA_CD, ACCUM_DEPR_FOBJ_CD)
/
CREATE INDEX CM_CPTLAST_OBJ_TI4
ON CM_CPTLAST_OBJ_T
(UNIV_FISCAL_YR, FIN_COA_CD, DEPR_EXP_FOBJ_CD)
/
-----------------------------------------------------------------------------
-- CM_CPTLAST_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CM_CPTLAST_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CM_CPTLAST_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CM_CPTLAST_T
(
CPTLAST_NBR NUMBER(12)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CPTLAST_DESC VARCHAR2(4000)
, CPTLAST_TYP_CD VARCHAR2(7)
, CPTLAST_COND_CD VARCHAR2(1)
, CPTLAST_CRT_DT DATE
, CPTLAST_RECEIVE_DT DATE
, CPTLAST_LN_RTRN_DT DATE
, CPTLAST_LOAN_DT DATE
, AST_EXPCTRETURN_DT DATE
, FDOC_POST_PRD_CD VARCHAR2(2)
, FDOC_POST_YR NUMBER(4)
, ORG_OWNER_ACCT_NBR VARCHAR2(7)
, ORG_OWNER_COA_CD VARCHAR2(2)
, CPTLAST_VENDOR_NM VARCHAR2(45)
, CPTLAST_ACQ_TYP_CD VARCHAR2(1)
, CPTLAST_TOTCST_AMT NUMBER(19,2)
, CPTLAST_RPLC_AMT NUMBER(19,2)
, CPTLAST_SALE_PRC NUMBER(19,2)
, AST_EST_SELL_PRC NUMBER(19,2)
, CPTLAST_SALVAG_AMT NUMBER(19,2)
, CAMPUS_CD VARCHAR2(2)
, BLDG_CD VARCHAR2(10)
, BLDG_ROOM_NBR VARCHAR2(8)
, BLDG_SUB_ROOM_NBR VARCHAR2(2)
, AST_RETIR_COA_CD VARCHAR2(2)
, AST_RETIR_ACCT_NBR VARCHAR2(7)
, AST_RETIRE_REAS_CD VARCHAR2(1)
, AST_RETIR_PRD_CD VARCHAR2(2)
, AST_RETIR_FSCL_YR NUMBER(4)
, CASH_RCPT_FDOC_NBR VARCHAR2(14)
, AST_DEPR_MTHD1_CD VARCHAR2(3)
, AST_ESTFABRCMPL_DT DATE
, AST_FABRESTTOT_AMT NUMBER(19,2)
, TRNFR_FND_FDOC_NBR VARCHAR2(14)
, AST_INVN_STAT_CD VARCHAR2(1)
, CPTLAST_TAG_NBR VARCHAR2(8)
, CPTLAST_LSTINVN_DT DATE
, ORG_INVN_NM VARCHAR2(40)
, CPTLAST_OLDTAG_NBR VARCHAR2(8)
, CPTLAST_MFR_NM VARCHAR2(45)
, CPTLAST_MFRMDL_NBR VARCHAR2(25)
, CPTLAST_SERIAL_NBR VARCHAR2(25)
, AST_REP_UNVL_ID VARCHAR2(40)
, CG_AGENCY_NBR VARCHAR2(5)
, AST_PD_CASE_NBR VARCHAR2(14)
, AST_INVN_SCAN_CD VARCHAR2(1)
, CPTL_AST_IN_SRVC_DT DATE
, CPTL_AST_GOV_TAG_NBR VARCHAR2(12)
, CPTL_AST_NTL_STOCK_NBR VARCHAR2(25)
, CPTL_AST_LAND_CNTY_NM VARCHAR2(20)
, CPTL_AST_LAND_ACRG_SZ NUMBER(7)
, CPTL_AST_LAND_PRCL_NBR VARCHAR2(30)
, CPTL_AST_DEPR_DT DATE
, FIN_OBJ_SUB_TYP_CD VARCHAR2(2)
, AST_FABR_EST_RETN_YRS NUMBER(5)
, CONSTRAINT CM_CPTLAST_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CM_CPTLAST_T
ADD CONSTRAINT CM_CPTLAST_TP1
PRIMARY KEY (CPTLAST_NBR)
/
CREATE INDEX CM_CPTLAST_TI2
ON CM_CPTLAST_T
(CPTLAST_TAG_NBR)
/
CREATE INDEX CM_CPTLAST_TI3
ON CM_CPTLAST_T
(AST_REP_UNVL_ID)
/
CREATE INDEX CM_CPTLAST_TI4
ON CM_CPTLAST_T
(CAMPUS_CD, BLDG_CD, BLDG_ROOM_NBR)
/
-----------------------------------------------------------------------------
-- CM_EQPLNRTRN_DOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CM_EQPLNRTRN_DOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CM_EQPLNRTRN_DOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CM_EQPLNRTRN_DOC_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CPTLAST_LOAN_DT DATE
, AST_EXPCTRETURN_DT DATE
, CPTLAST_LN_RTRN_DT DATE
, AST_BORWR_UNVL_ID VARCHAR2(40)
, AST_BORWR_ADDR VARCHAR2(30)
, AST_BORWR_CITY_NM VARCHAR2(25)
, AST_BORWR_STATE_CD VARCHAR2(2)
, AST_BORWR_ZIP_CD VARCHAR2(20)
, AST_BORWR_CNTRY_CD VARCHAR2(2)
, AST_BORWR_PHN_NBR VARCHAR2(13)
, AST_BORWRSTRG_ADDR VARCHAR2(30)
, AST_BORWRSTRGCT_NM VARCHAR2(25)
, AST_BORWRSTRGST_CD VARCHAR2(2)
, AST_BORWRSTRGZP_CD VARCHAR2(20)
, AST_BORWRSTRCNT_CD VARCHAR2(2)
, AST_BORWRSTRPH_NBR VARCHAR2(13)
, CPTLAST_NBR NUMBER(12)
, CONSTRAINT CM_EQPLNRTRN_DOC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CM_EQPLNRTRN_DOC_T
ADD CONSTRAINT CM_EQPLNRTRN_DOC_TP1
PRIMARY KEY (FDOC_NBR)
/
CREATE INDEX CM_EQPLNRTRN_DOC_TI2
ON CM_EQPLNRTRN_DOC_T
(AST_BORWR_UNVL_ID)
/
-----------------------------------------------------------------------------
-- CM_FSCL_YR_END_DEPR_DTL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CM_FSCL_YR_END_DEPR_DTL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CM_FSCL_YR_END_DEPR_DTL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CM_FSCL_YR_END_DEPR_DTL_T
(
UNIV_FISCAL_YR NUMBER(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) NOT NULL
, CPTLAST_NBR NUMBER(12)
, YEAR_END_DEPR_DTL_ACTV_IND VARCHAR2(1)
, YEAR_END_DEPR_DTL_PROC_IND VARCHAR2(1)
)
/
ALTER TABLE CM_FSCL_YR_END_DEPR_DTL_T
ADD CONSTRAINT CM_FSCL_YR_END_DEPR_DTL_TP1
PRIMARY KEY (UNIV_FISCAL_YR,CPTLAST_NBR)
/
-----------------------------------------------------------------------------
-- CM_FSCL_YR_END_DEPR_HDR_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CM_FSCL_YR_END_DEPR_HDR_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CM_FSCL_YR_END_DEPR_HDR_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CM_FSCL_YR_END_DEPR_HDR_T
(
UNIV_FISCAL_YR NUMBER(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, YEAR_END_DEPR_RUN_DATE DATE
, YEAR_END_DEPR_ACTV_IND VARCHAR2(1)
)
/
ALTER TABLE CM_FSCL_YR_END_DEPR_HDR_T
ADD CONSTRAINT CM_FSCL_YR_END_DEPR_HDR_TP1
PRIMARY KEY (UNIV_FISCAL_YR)
/
-----------------------------------------------------------------------------
-- CM_INVN_ERR_DOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CM_INVN_ERR_DOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CM_INVN_ERR_DOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CM_INVN_ERR_DOC_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, AST_UPLDR_UNVL_ID VARCHAR2(40)
, CONSTRAINT CM_INVN_ERR_DOC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CM_INVN_ERR_DOC_T
ADD CONSTRAINT CM_INVN_ERR_DOC_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- CM_INVN_ERR_DTL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CM_INVN_ERR_DTL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CM_INVN_ERR_DTL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CM_INVN_ERR_DTL_T
(
FDOC_NBR VARCHAR2(14)
, AST_UPLD_ROW_NBR NUMBER(12)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, AST_ERRCOR_STAT_CD VARCHAR2(1)
, AST_COR_UNVL_ID VARCHAR2(40)
, AST_INVN_COR_TS DATE
, CPTLAST_TAG_NBR VARCHAR2(8)
, AST_UPLD_SCAN_IND VARCHAR2(1)
, AST_UPLD_SCAN_TS DATE
, CAMPUS_CD VARCHAR2(2)
, BLDG_CD VARCHAR2(10)
, BLDG_ROOM_NBR VARCHAR2(8)
, BLDG_SUB_ROOM_NBR VARCHAR2(2)
, CPTLAST_COND_CD VARCHAR2(1)
, CONSTRAINT CM_INVN_ERR_DTL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CM_INVN_ERR_DTL_T
ADD CONSTRAINT CM_INVN_ERR_DTL_TP1
PRIMARY KEY (FDOC_NBR,AST_UPLD_ROW_NBR)
/
-----------------------------------------------------------------------------
-- CM_RETIRE_REAS_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'CM_RETIRE_REAS_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE CM_RETIRE_REAS_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE CM_RETIRE_REAS_T
(
AST_RETIRE_REAS_CD VARCHAR2(1)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, AST_RETIRE_REAS_NM VARCHAR2(40)
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, AST_RETIRE_REAS_RSTR_IND VARCHAR2(1) NOT NULL
, CONSTRAINT CM_RETIRE_REAS_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE CM_RETIRE_REAS_T
ADD CONSTRAINT CM_RETIRE_REAS_TP1
PRIMARY KEY (AST_RETIRE_REAS_CD)
/
-----------------------------------------------------------------------------
-- DATABASECHANGELOG
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'DATABASECHANGELOG';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE DATABASECHANGELOG CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE DATABASECHANGELOG
(
ID VARCHAR2(63)
, AUTHOR VARCHAR2(63)
, FILENAME VARCHAR2(200)
, DATEEXECUTED TIMESTAMP NOT NULL
, ORDEREXECUTED NUMBER(22) NOT NULL
, EXECTYPE VARCHAR2(10) NOT NULL
, MD5SUM VARCHAR2(35)
, DESCRIPTION VARCHAR2(255)
, COMMENTS VARCHAR2(255)
, TAG VARCHAR2(255)
, LIQUIBASE VARCHAR2(20)
)
/
ALTER TABLE DATABASECHANGELOG
ADD CONSTRAINT DATABASECHANGELOGP1
PRIMARY KEY (ID,AUTHOR,FILENAME)
/
-----------------------------------------------------------------------------
-- DATABASECHANGELOGLOCK
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'DATABASECHANGELOGLOCK';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE DATABASECHANGELOGLOCK CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE DATABASECHANGELOGLOCK
(
ID NUMBER(22)
, LOCKED NUMBER(1) NOT NULL
, LOCKGRANTED TIMESTAMP
, LOCKEDBY VARCHAR2(255)
)
/
ALTER TABLE DATABASECHANGELOGLOCK
ADD CONSTRAINT DATABASECHANGELOGLOCKP1
PRIMARY KEY (ID)
/
-----------------------------------------------------------------------------
-- ER_CTRL_ATTRIB_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'ER_CTRL_ATTRIB_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE ER_CTRL_ATTRIB_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE ER_CTRL_ATTRIB_TYP_T
(
CTRL_ATTRIB_TYP_CD VARCHAR2(1)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, REQD_IND VARCHAR2(1)
, CTRL_ATTRIB_TYP_DESC VARCHAR2(100)
, CONSTRAINT ER_CTRL_ATTRIB_TYP_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE ER_CTRL_ATTRIB_TYP_T
ADD CONSTRAINT ER_CTRL_ATTRIB_TYP_TP1
PRIMARY KEY (CTRL_ATTRIB_TYP_CD)
/
-----------------------------------------------------------------------------
-- ER_RSRCH_RSK_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'ER_RSRCH_RSK_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE ER_RSRCH_RSK_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE ER_RSRCH_RSK_TYP_T
(
RSRCH_RSK_TYP_CD VARCHAR2(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CTRL_ATTRIB_TYP_CD VARCHAR2(1) NOT NULL
, RSRCH_RSK_TYP_DESC VARCHAR2(30)
, RSRCH_RSK_TYP_SORT_NBR NUMBER(2)
, RSRCH_RSK_TYP_NTFCTN_VAL VARCHAR2(8)
, CONSTRAINT ER_RSRCH_RSK_TYP_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE ER_RSRCH_RSK_TYP_T
ADD CONSTRAINT ER_RSRCH_RSK_TYP_TP1
PRIMARY KEY (RSRCH_RSK_TYP_CD)
/
-----------------------------------------------------------------------------
-- FP_ACCT_LINES_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_ACCT_LINES_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_ACCT_LINES_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_ACCT_LINES_T
(
FDOC_NBR VARCHAR2(14)
, FDOC_LINE_NBR NUMBER(7)
, FDOC_LN_TYP_CD VARCHAR2(1)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, FDOC_POST_YR NUMBER(4)
, FIN_OBJECT_CD VARCHAR2(4)
, FIN_BALANCE_TYP_CD VARCHAR2(2)
, FDOC_LINE_AMT NUMBER(19,2)
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, PROJECT_CD VARCHAR2(10)
, ORG_REFERENCE_ID VARCHAR2(8)
, FS_REF_ORIGIN_CD VARCHAR2(2)
, FDOC_REF_NBR VARCHAR2(14)
, FDOC_REF_TYP_CD VARCHAR2(8)
, FDOC_OVERRIDE_CD VARCHAR2(100)
, FDOC_LINE_DESC VARCHAR2(40)
, FDOC_LINE_DBCR_CD VARCHAR2(1)
, TRN_ENCUM_UPDT_CD VARCHAR2(1)
, CONSTRAINT FP_ACCT_LINES_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_ACCT_LINES_T
ADD CONSTRAINT FP_ACCT_LINES_TP1
PRIMARY KEY (FDOC_NBR,FDOC_LINE_NBR,FDOC_LN_TYP_CD)
/
-----------------------------------------------------------------------------
-- FP_ACRL_VCHR_DOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_ACRL_VCHR_DOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_ACRL_VCHR_DOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_ACRL_VCHR_DOC_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_NXT_LINE_NBR NUMBER(7)
, FDOC_POST_YR NUMBER(4)
, FDOC_POST_PRD_CD VARCHAR2(2)
, FDOC_REVERSAL_DT DATE
, FDOC_AV_TYP_CD VARCHAR2(8)
, CONSTRAINT FP_ACRL_VCHR_DOC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_ACRL_VCHR_DOC_T
ADD CONSTRAINT FP_ACRL_VCHR_DOC_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- FP_ADV_DPST_DTL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_ADV_DPST_DTL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_ADV_DPST_DTL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_ADV_DPST_DTL_T
(
FDOC_NBR VARCHAR2(14)
, FDOC_TYP_CD VARCHAR2(8)
, FDOC_LINE_NBR NUMBER(7)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_ADV_DPST_DT DATE
, FDOC_ADPST_REF_NBR VARCHAR2(10)
, FDOC_ADV_DPST_DESC VARCHAR2(40)
, FDOC_ADV_DPST_AMT NUMBER(19,2)
, FDOC_BANK_CD VARCHAR2(4)
, CONSTRAINT FP_ADV_DPST_DTL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_ADV_DPST_DTL_T
ADD CONSTRAINT FP_ADV_DPST_DTL_TP1
PRIMARY KEY (FDOC_NBR,FDOC_TYP_CD,FDOC_LINE_NBR)
/
-----------------------------------------------------------------------------
-- FP_BAL_BY_CONS_MT
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_BAL_BY_CONS_MT';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_BAL_BY_CONS_MT CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_BAL_BY_CONS_MT
(
SESID VARCHAR2(36)
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_REPORT_SORT_CD VARCHAR2(2)
, CONS_FIN_REPORT_SORT_CD VARCHAR2(2)
, FIN_CONS_OBJ_CD VARCHAR2(4)
, VER_NBR NUMBER(8) default 1 NOT NULL
, CURR_BDLN_BAL_AMT NUMBER(19,2)
, ACLN_ACTLS_BAL_AMT NUMBER(19,2)
, ACLN_ENCUM_BAL_AMT NUMBER(19,2)
, ACCTG_CTGRY_CD VARCHAR2(2)
)
/
ALTER TABLE FP_BAL_BY_CONS_MT
ADD CONSTRAINT FP_BAL_BY_CONS_MTP1
PRIMARY KEY (SESID,SUB_ACCT_NBR,FIN_REPORT_SORT_CD,CONS_FIN_REPORT_SORT_CD,FIN_CONS_OBJ_CD)
/
-----------------------------------------------------------------------------
-- FP_BAL_BY_LEVEL_MT
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_BAL_BY_LEVEL_MT';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_BAL_BY_LEVEL_MT CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_BAL_BY_LEVEL_MT
(
SESID VARCHAR2(36)
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_OBJ_LEVEL_CD VARCHAR2(4)
, FIN_REPORT_SORT_CD VARCHAR2(2)
, VER_NBR NUMBER(8) default 1 NOT NULL
, CURR_BDLN_BAL_AMT NUMBER(19,2)
, ACLN_ACTLS_BAL_AMT NUMBER(19,2)
, ACLN_ENCUM_BAL_AMT NUMBER(19,2)
, TYP_FIN_REPORT_SORT_CD VARCHAR2(2)
, ACCTG_CTGRY_CD VARCHAR2(2)
)
/
ALTER TABLE FP_BAL_BY_LEVEL_MT
ADD CONSTRAINT FP_BAL_BY_LEVEL_MTP1
PRIMARY KEY (SESID,SUB_ACCT_NBR,FIN_OBJ_LEVEL_CD,FIN_REPORT_SORT_CD)
/
-----------------------------------------------------------------------------
-- FP_BAL_BY_OBJ_MT
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_BAL_BY_OBJ_MT';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_BAL_BY_OBJ_MT CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_BAL_BY_OBJ_MT
(
SESID VARCHAR2(36)
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_OBJECT_CD VARCHAR2(4)
, VER_NBR NUMBER(8) default 1 NOT NULL
, CURR_BDLN_BAL_AMT NUMBER(19,2)
, ACLN_ACTLS_BAL_AMT NUMBER(19,2)
, ACLN_ENCUM_BAL_AMT NUMBER(19,2)
, FIN_REPORT_SORT_CD VARCHAR2(2)
, ACCTG_CTGRY_CD VARCHAR2(2)
)
/
ALTER TABLE FP_BAL_BY_OBJ_MT
ADD CONSTRAINT FP_BAL_BY_OBJ_MTP1
PRIMARY KEY (SESID,SUB_ACCT_NBR,FIN_OBJECT_CD)
/
-----------------------------------------------------------------------------
-- FP_BANK_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_BANK_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_BANK_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_BANK_T
(
BNK_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, BNK_NM VARCHAR2(40)
, BNK_SHRT_NM VARCHAR2(12)
, BNK_RTNG_NBR VARCHAR2(9)
, ROW_ACTV_IND VARCHAR2(1) default 'Y' NOT NULL
, BNK_ACCT_NBR VARCHAR2(255) default '3JQZbNFD6os=' NOT NULL
, BNK_ACCT_DESC VARCHAR2(40)
, CSH_OFST_FIN_COA_CD VARCHAR2(2)
, CSH_OFST_ACCT_NBR VARCHAR2(7)
, CSH_OFST_SUB_ACCT_NBR VARCHAR2(5)
, CSH_OFST_OBJ_CD VARCHAR2(4)
, CSH_OFST_SUB_OBJ_CD VARCHAR2(3)
, CONT_BNK_CD VARCHAR2(4)
, BNK_DPST_IND VARCHAR2(1) default 'Y' NOT NULL
, BNK_DISB_IND VARCHAR2(1) default 'Y' NOT NULL
, BNK_ACH_IND VARCHAR2(1) default 'Y' NOT NULL
, BNK_CHK_IND VARCHAR2(1) default 'Y' NOT NULL
, CONSTRAINT FP_BANK_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_BANK_T
ADD CONSTRAINT FP_BANK_TP1
PRIMARY KEY (BNK_CD)
/
-----------------------------------------------------------------------------
-- FP_BDGT_ADJ_DOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_BDGT_ADJ_DOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_BDGT_ADJ_DOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_BDGT_ADJ_DOC_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_NXT_FRM_NBR NUMBER(7)
, FDOC_NXT_TO_NBR NUMBER(7)
, FDOC_NXT_PSFRM_NBR NUMBER(7)
, FDOC_NXT_PSTO_NBR NUMBER(7)
, FDOC_POST_YR NUMBER(4)
, FDOC_POST_PRD_CD VARCHAR2(2)
, CONSTRAINT FP_BDGT_ADJ_DOC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_BDGT_ADJ_DOC_T
ADD CONSTRAINT FP_BDGT_ADJ_DOC_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- FP_BDGT_ADJ_DTL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_BDGT_ADJ_DTL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_BDGT_ADJ_DTL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_BDGT_ADJ_DTL_T
(
FDOC_NBR VARCHAR2(14)
, FDOC_LINE_NBR NUMBER(7)
, FDOC_LN_TYP_CD VARCHAR2(1)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, BDGT_ADJ_PRD_CD VARCHAR2(2)
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, FDOC_POST_YR NUMBER(4)
, FIN_OBJECT_CD VARCHAR2(4)
, CURR_BDGT_ADJ_AMT NUMBER(19,2)
, BASE_BDGT_ADJ_AMT NUMBER(19,2)
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, PROJECT_CD VARCHAR2(10)
, FDOC_OVERRIDE_CD VARCHAR2(100)
, ORG_REFERENCE_ID VARCHAR2(8)
, FDOC_LN_MO1_AMT NUMBER(19,2)
, FDOC_LN_MO2_AMT NUMBER(19,2)
, FDOC_LN_MO3_AMT NUMBER(19,2)
, FDOC_LN_MO4_AMT NUMBER(19,2)
, FDOC_LN_MO5_AMT NUMBER(19,2)
, FDOC_LN_MO6_AMT NUMBER(19,2)
, FDOC_LN_MO7_AMT NUMBER(19,2)
, FDOC_LN_MO8_AMT NUMBER(19,2)
, FDOC_LN_MO9_AMT NUMBER(19,2)
, FDOC_LN_MO10_AMT NUMBER(19,2)
, FDOC_LN_MO11_AMT NUMBER(19,2)
, FDOC_LN_MO12_AMT NUMBER(19,2)
, FRNG_BENE_IND VARCHAR2(1)
, CONSTRAINT FP_BDGT_ADJ_DTL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_BDGT_ADJ_DTL_T
ADD CONSTRAINT FP_BDGT_ADJ_DTL_TP1
PRIMARY KEY (FDOC_NBR,FDOC_LINE_NBR,FDOC_LN_TYP_CD)
/
CREATE INDEX FP_BDGT_ADJ_DTL_TI2
ON FP_BDGT_ADJ_DTL_T
(FIN_COA_CD, ACCOUNT_NBR)
/
CREATE INDEX FP_BDGT_ADJ_DTL_TI3
ON FP_BDGT_ADJ_DTL_T
(FDOC_POST_YR, FIN_COA_CD, FIN_OBJECT_CD)
/
-----------------------------------------------------------------------------
-- FP_CASHIER_DOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_CASHIER_DOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_CASHIER_DOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_CASHIER_DOC_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, DPST_FS_ORIG_CD VARCHAR2(2)
, DPST_FDOC_NBR VARCHAR2(14)
, FDOC_CHCK_AMT NUMBER(19,2)
, FDOC_ADV_DPST_AMT NUMBER(19,2)
, FDOC_REVOLVFND_AMT NUMBER(19,2)
, FDOC_NXT_CC_LN_NBR NUMBER(7)
, FDOC_CASH_AMT NUMBER(19,2)
, FDOC_CRDT_CARD_AMT NUMBER(19,2)
, FDOC_TOTL_COIN_AMT NUMBER(19,2)
, FDOC_CHANGEOUT_AMT NUMBER(19,2)
, FDOC_NXT_CK_LN_NBR NUMBER(7)
, FDOC_NXT_AD_LN_NBR NUMBER(7)
, FDOC_NXT_RF_LN_NBR NUMBER(7)
, CONSTRAINT FP_CASHIER_DOC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_CASHIER_DOC_T
ADD CONSTRAINT FP_CASHIER_DOC_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- FP_CASHIER_ITM_IN_PROC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_CASHIER_ITM_IN_PROC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_CASHIER_ITM_IN_PROC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_CASHIER_ITM_IN_PROC_T
(
CAMPUS_CD VARCHAR2(2)
, ITM_ID NUMBER(9)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ITM_AMT NUMBER(19,2)
, ITM_RDCD_AMT NUMBER(19,2)
, ITM_TOT_AMT NUMBER(19,2)
, ITM_OPEN_DT DATE
, ITM_CLOSED_DT DATE
, ITM_DESC VARCHAR2(200)
, CONSTRAINT FP_CASHIER_ITM_IN_PROC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_CASHIER_ITM_IN_PROC_T
ADD CONSTRAINT FP_CASHIER_ITM_IN_PROC_TP1
PRIMARY KEY (CAMPUS_CD,ITM_ID)
/
-----------------------------------------------------------------------------
-- FP_CASH_RCPT_DOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_CASH_RCPT_DOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_CASH_RCPT_DOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_CASH_RCPT_DOC_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_NXT_LINE_NBR NUMBER(7)
, FDOC_POST_YR NUMBER(4)
, FDOC_POST_PRD_CD VARCHAR2(2)
, FDOC_CASH_AMT NUMBER(19,2)
, FDOC_TOTL_CHCK_AMT NUMBER(19,2)
, FDOC_TOTL_COIN_AMT NUMBER(19,2)
, FDOC_CHANGEOUT_AMT NUMBER(19,2)
, FDOC_CRDT_CARD_AMT NUMBER(19,2)
, FDOC_NONCASH_AMT NUMBER(19,2)
, FDOC_REVOLVFND_AMT NUMBER(19,2)
, FDOC_ADV_DPST_AMT NUMBER(19,2)
, FDOC_NXT_CK_LN_NBR NUMBER(7)
, FDC_NXTCC_CRLN_NBR NUMBER(7)
, FDOC_NXT_RF_LN_NBR NUMBER(7)
, FDOC_NXT_AD_LN_NBR NUMBER(7)
, CAMPUS_CD VARCHAR2(2)
, FDOC_DEPOSIT_DT DATE
, FDOC_CNFRMD_CASH_AMT NUMBER(19,2)
, FDOC_CNFRMD_CHCK_AMT NUMBER(19,2)
, FDOC_CNFRMD_COIN_AMT NUMBER(19,2)
, FDOC_BNK_CD VARCHAR2(4)
, CONSTRAINT FP_CASH_RCPT_DOC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_CASH_RCPT_DOC_T
ADD CONSTRAINT FP_CASH_RCPT_DOC_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- FP_CHECK_DTL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_CHECK_DTL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_CHECK_DTL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_CHECK_DTL_T
(
FDOC_NBR VARCHAR2(14)
, FDOC_TYP_CD VARCHAR2(8)
, FDOC_COLUMN_TYP_CD VARCHAR2(1)
, FDOC_LINE_NBR NUMBER(7)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_CHCK_NBR VARCHAR2(10)
, FDOC_CHCK_DT DATE
, FDOC_CHCK_DESC VARCHAR2(40)
, FDOC_CHCK_AMT NUMBER(19,2)
, FDOC_DPST_LN_NBR NUMBER(7)
, CSHR_STAT_CD VARCHAR2(1)
, CONSTRAINT FP_CHECK_DTL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_CHECK_DTL_T
ADD CONSTRAINT FP_CHECK_DTL_TP1
PRIMARY KEY (FDOC_NBR,FDOC_TYP_CD,FDOC_LINE_NBR,CSHR_STAT_CD)
/
-----------------------------------------------------------------------------
-- FP_COIN_DTL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_COIN_DTL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_COIN_DTL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_COIN_DTL_T
(
FDOC_NBR VARCHAR2(14)
, FDOC_TYP_CD VARCHAR2(8)
, FDOC_COLUMN_TYP_CD VARCHAR2(1)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_50_CENT_AMT NUMBER(19,2)
, FDOC_25_CENT_AMT NUMBER(19,2)
, FDOC_10_CENT_AMT NUMBER(19,2)
, FDOC_5_CENT_AMT NUMBER(19,2)
, FDOC_1_CENT_AMT NUMBER(19,2)
, FDOC_OTHR_CENT_AMT NUMBER(19,2)
, FDOC_100_CENT_AMT NUMBER(19,2)
, CSHR_STAT_CD VARCHAR2(1)
, CONSTRAINT FP_COIN_DTL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_COIN_DTL_T
ADD CONSTRAINT FP_COIN_DTL_TP1
PRIMARY KEY (FDOC_NBR,FDOC_TYP_CD,CSHR_STAT_CD)
/
-----------------------------------------------------------------------------
-- FP_CPTL_AST_ACCT_GRP_DTL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_CPTL_AST_ACCT_GRP_DTL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_CPTL_AST_ACCT_GRP_DTL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_CPTL_AST_ACCT_GRP_DTL_T
(
FDOC_NBR VARCHAR2(14)
, CPTLAST_LINE_NBR NUMBER(7) default 1
, CPTLAST_ACCTLINE_NBR NUMBER(7) default 1
, FDOC_LINE_NBR NUMBER(7) default 1
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_LN_TYP_CD VARCHAR2(1)
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, FIN_OBJECT_CD VARCHAR2(4)
, FDOC_LINE_AMT NUMBER(19,2) default 0.00
, CONSTRAINT FP_CPTL_AST_ACCT_GRP_DTL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_CPTL_AST_ACCT_GRP_DTL_T
ADD CONSTRAINT FP_CPTL_AST_ACCT_GRP_DTL_TP1
PRIMARY KEY (FDOC_NBR,CPTLAST_LINE_NBR,CPTLAST_ACCTLINE_NBR,FDOC_LINE_NBR)
/
-----------------------------------------------------------------------------
-- FP_CPTL_AST_INFO_DTL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_CPTL_AST_INFO_DTL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_CPTL_AST_INFO_DTL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_CPTL_AST_INFO_DTL_T
(
FDOC_NBR VARCHAR2(14)
, ITM_LN_NBR NUMBER(3)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CAMPUS_CD VARCHAR2(2)
, BLDG_CD VARCHAR2(10)
, BLDG_ROOM_NBR VARCHAR2(8)
, BLDG_SUB_ROOM_NBR VARCHAR2(2)
, CPTLAST_TAG_NBR VARCHAR2(8)
, CPTLAST_SERIAL_NBR VARCHAR2(25)
, FDOC_LINE_NBR NUMBER(7) default 1 NOT NULL
, FDOC_LN_TYP_CD VARCHAR2(1) NOT NULL
, FIN_COA_CD VARCHAR2(2) NOT NULL
, ACCOUNT_NBR VARCHAR2(7) NOT NULL
, FIN_OBJECT_CD VARCHAR2(4) NOT NULL
, CPTLAST_LINE_NBR NUMBER(7) default 1
, CONSTRAINT FP_CPTL_AST_INFO_DTL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_CPTL_AST_INFO_DTL_T
ADD CONSTRAINT FP_CPTL_AST_INFO_DTL_TP1
PRIMARY KEY (FDOC_NBR,ITM_LN_NBR)
/
-----------------------------------------------------------------------------
-- FP_CPTL_AST_INFO_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_CPTL_AST_INFO_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_CPTL_AST_INFO_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_CPTL_AST_INFO_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, VNDR_HDR_GNRTD_ID NUMBER(10)
, VNDR_DTL_ASND_ID NUMBER(10)
, CPTLAST_NBR NUMBER(12)
, CPTLAST_TYP_CD VARCHAR2(7)
, CPTLAST_MFR_NM VARCHAR2(45)
, CPTLAST_DESC VARCHAR2(4000)
, CPTLAST_MFRMDL_NBR VARCHAR2(25)
, CPTLAST_PROCESSED_IND CHAR(1) default 'N'
, CPTLAST_LINE_QTY NUMBER(7) default 0
, CPTLAST_LINE_AMT NUMBER(19,2) default 0.00
, CPTLAST_ACTION_IND VARCHAR2(1) default 'C' NOT NULL
, CPTLAST_LINE_NBR NUMBER(7) default 1 NOT NULL
, FDOC_LINE_AMT NUMBER(19,2) default 0.00
, FDOC_LINE_NBR NUMBER(7) default 1
, FDOC_LN_TYP_CD VARCHAR2(1)
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, FIN_OBJECT_CD VARCHAR2(4)
, CPTLAST_DST_AMT_CD VARCHAR2(1) default '1'
, CONSTRAINT FP_CPTL_AST_INFO_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_CPTL_AST_INFO_T
ADD CONSTRAINT FP_CPTL_AST_INFO_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- FP_CR_CARD_DTL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_CR_CARD_DTL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_CR_CARD_DTL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_CR_CARD_DTL_T
(
FDOC_NBR VARCHAR2(14)
, FDOC_TYP_CD VARCHAR2(8)
, FDOC_LINE_NBR NUMBER(7)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_CCRD_TYP_CD VARCHAR2(2)
, FDOC_CCRD_VNDR_NBR VARCHAR2(10)
, FDOC_CCRD_DPST_DT DATE
, FDOC_CCRD_DREF_NBR VARCHAR2(10)
, FDOC_CCRD_DPST_AMT NUMBER(19,2)
, CONSTRAINT FP_CR_CARD_DTL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_CR_CARD_DTL_T
ADD CONSTRAINT FP_CR_CARD_DTL_TP1
PRIMARY KEY (FDOC_NBR,FDOC_TYP_CD,FDOC_LINE_NBR)
/
-----------------------------------------------------------------------------
-- FP_CR_CARD_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_CR_CARD_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_CR_CARD_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_CR_CARD_TYP_T
(
FDOC_CCRD_TYP_CD VARCHAR2(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_CCRD_CMPNY_NM VARCHAR2(40)
, ROW_ACTV_IND VARCHAR2(1) default 'Y' NOT NULL
, CONSTRAINT FP_CR_CARD_TYP_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_CR_CARD_TYP_T
ADD CONSTRAINT FP_CR_CARD_TYP_TP1
PRIMARY KEY (FDOC_CCRD_TYP_CD)
/
-----------------------------------------------------------------------------
-- FP_CR_CARD_VNDR_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_CR_CARD_VNDR_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_CR_CARD_VNDR_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_CR_CARD_VNDR_T
(
FDOC_CCRD_VNDR_NBR VARCHAR2(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_CCRD_VNDR_NM VARCHAR2(40)
, FDOC_CCRD_TYP_CD VARCHAR2(2)
, INC_FIN_COA_CD VARCHAR2(2)
, INC_ACCT_NBR VARCHAR2(7)
, INC_FIN_OBJ_CD VARCHAR2(4)
, INC_FIN_SUB_OBJ_CD VARCHAR2(3)
, INC_SUB_ACCT_NBR VARCHAR2(5)
, EXP_FIN_COA_CD VARCHAR2(2)
, EXP_ACCT_NBR VARCHAR2(7)
, EXP_FIN_OBJ_CD VARCHAR2(4)
, EXP_FIN_SUB_OBJ_CD VARCHAR2(3)
, EXP_SUB_ACCT_NBR VARCHAR2(5)
, ROW_ACTV_IND VARCHAR2(1) default 'Y' NOT NULL
, CONSTRAINT FP_CR_CARD_VNDR_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_CR_CARD_VNDR_T
ADD CONSTRAINT FP_CR_CARD_VNDR_TP1
PRIMARY KEY (FDOC_CCRD_VNDR_NBR)
/
-----------------------------------------------------------------------------
-- FP_CSH_DRWR_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_CSH_DRWR_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_CSH_DRWR_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_CSH_DRWR_T
(
CAMPUS_CD VARCHAR2(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_OPEN_DPST_CD VARCHAR2(1)
, CSH_DRWR_TOT_AMT NUMBER(19,2)
, FDOC_100_DLR_AMT NUMBER(19,2)
, FDOC_50_DLR_AMT NUMBER(19,2)
, FDOC_20_DLR_AMT NUMBER(19,2)
, FDOC_10_DLR_AMT NUMBER(19,2)
, FDOC_5_DLR_AMT NUMBER(19,2)
, FDOC_2_DLR_AMT NUMBER(19,2)
, FDOC_1_DLR_AMT NUMBER(19,2)
, FDOC_OTHR_DLR_AMT NUMBER(19,2)
, FDOC_50_CENT_AMT NUMBER(19,2)
, FDOC_25_CENT_AMT NUMBER(19,2)
, FDOC_10_CENT_AMT NUMBER(19,2)
, FDOC_5_CENT_AMT NUMBER(19,2)
, FDOC_1_CENT_AMT NUMBER(19,2)
, FDOC_OTHR_CENT_AMT NUMBER(19,2)
, FDOC_100_CENT_AMT NUMBER(19,2)
, FDOC_MISC_ADV_AMT NUMBER(19,2)
, FDOC_REF_NBR VARCHAR2(14)
, CONSTRAINT FP_CSH_DRWR_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_CSH_DRWR_T
ADD CONSTRAINT FP_CSH_DRWR_TP1
PRIMARY KEY (CAMPUS_CD)
/
-----------------------------------------------------------------------------
-- FP_CURRENCY_DTL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_CURRENCY_DTL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_CURRENCY_DTL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_CURRENCY_DTL_T
(
FDOC_NBR VARCHAR2(14)
, FDOC_TYP_CD VARCHAR2(8)
, FDOC_COLUMN_TYP_CD VARCHAR2(1)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_100_DLR_AMT NUMBER(19,2)
, FDOC_50_DLR_AMT NUMBER(19,2)
, FDOC_20_DLR_AMT NUMBER(19,2)
, FDOC_10_DLR_AMT NUMBER(19,2)
, FDOC_5_DLR_AMT NUMBER(19,2)
, FDOC_2_DLR_AMT NUMBER(19,2)
, FDOC_1_DLR_AMT NUMBER(19,2)
, FDOC_OTHR_DLR_AMT NUMBER(19,2)
, CSHR_STAT_CD VARCHAR2(1)
, CONSTRAINT FP_CURRENCY_DTL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_CURRENCY_DTL_T
ADD CONSTRAINT FP_CURRENCY_DTL_TP1
PRIMARY KEY (FDOC_NBR,FDOC_TYP_CD,CSHR_STAT_CD)
/
-----------------------------------------------------------------------------
-- FP_CUST_CC_INFO_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_CUST_CC_INFO_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_CUST_CC_INFO_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_CUST_CC_INFO_T
(
CUST_CCRD_NBR VARCHAR2(16)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CUST_CCRD_HLDR_NM VARCHAR2(123)
, CUST_CCRD_ISSR_NM VARCHAR2(123)
, FDOC_CCRD_TYPE_CD VARCHAR2(2)
, CUST_CCRD_EXP_DT DATE
, CUST_NBR VARCHAR2(9)
, FIDOC_CCRD_VNDR_NBR VARCHAR2(10)
, CUST_CCRD_NTE_TXT VARCHAR2(2000)
, CONSTRAINT FP_CUST_CC_INFO_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_CUST_CC_INFO_T
ADD CONSTRAINT FP_CUST_CC_INFO_TP1
PRIMARY KEY (CUST_CCRD_NBR)
/
CREATE INDEX FP_CUST_CC_INFO_TI1
ON FP_CUST_CC_INFO_T
(FIDOC_CCRD_VNDR_NBR)
/
-----------------------------------------------------------------------------
-- FP_DEPOSIT_DOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_DEPOSIT_DOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_DEPOSIT_DOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_DEPOSIT_DOC_T
(
FDOC_NBR VARCHAR2(14)
, FDOC_LINE_NBR NUMBER(7)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_DPST_TYP_CD VARCHAR2(1)
, FDOC_DPST_DT DATE
, FDOC_DPST_BNK_CD VARCHAR2(4)
, FDOC_DPST_TKT_NBR VARCHAR2(20)
, FDOC_DPST_AMT NUMBER(19,2)
, CONSTRAINT FP_DEPOSIT_DOC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_DEPOSIT_DOC_T
ADD CONSTRAINT FP_DEPOSIT_DOC_TP1
PRIMARY KEY (FDOC_NBR,FDOC_LINE_NBR)
/
-----------------------------------------------------------------------------
-- FP_DEPOSIT_HDR_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_DEPOSIT_HDR_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_DEPOSIT_HDR_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_DEPOSIT_HDR_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CAMPUS_CD VARCHAR2(2)
, FDOC_MSTR_100_DLR_AMT NUMBER(19,2)
, FDOC_MSTR_50_DLR_AMT NUMBER(19,2)
, FDOC_MSTR_20_DLR_AMT NUMBER(19,2)
, FDOC_MSTR_10_DLR_AMT NUMBER(19,2)
, FDOC_MSTR_5_DLR_AMT NUMBER(19,2)
, FDOC_MSTR_2_DLR_AMT NUMBER(19,2)
, FDOC_MSTR_1_DLR_AMT NUMBER(19,2)
, FDOC_MSTR_OTHR_DLR_AMT NUMBER(19,2)
, FDOC_MSTR_100_CENT_AMT NUMBER(19,2)
, FDOC_MSTR_50_CENT_AMT NUMBER(19,2)
, FDOC_MSTR_25_CENT_AMT NUMBER(19,2)
, FDOC_MSTR_10_CENT_AMT NUMBER(19,2)
, FDOC_MSTR_5_CENT_AMT NUMBER(19,2)
, FDOC_MSTR_1_CENT_AMT NUMBER(19,2)
, FDOC_MSTR_OTHR_CENT_AMT NUMBER(19,2)
, CONSTRAINT FP_DEPOSIT_HDR_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_DEPOSIT_HDR_T
ADD CONSTRAINT FP_DEPOSIT_HDR_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- FP_DEP_CSH_RCPT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_DEP_CSH_RCPT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_DEP_CSH_RCPT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_DEP_CSH_RCPT_T
(
FDOC_DPST_NBR VARCHAR2(14)
, FDOC_LINE_NBR NUMBER(7)
, FDOC_CSH_RCPT_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FS_CSHRCPT_PRCS_TS DATE
, FS_PRCS_OPR_ID VARCHAR2(10)
, CONSTRAINT FP_DEP_CSH_RCPT_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_DEP_CSH_RCPT_T
ADD CONSTRAINT FP_DEP_CSH_RCPT_TP1
PRIMARY KEY (FDOC_DPST_NBR,FDOC_LINE_NBR,FDOC_CSH_RCPT_NBR)
/
CREATE INDEX FP_DEP_CSH_RCPT_TI2
ON FP_DEP_CSH_RCPT_T
(FDOC_CSH_RCPT_NBR)
/
-----------------------------------------------------------------------------
-- FP_DISTRIB_DOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_DISTRIB_DOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_DISTRIB_DOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_DISTRIB_DOC_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_NXT_FRM_NBR NUMBER(7)
, FDOC_NXT_TO_NBR NUMBER(7)
, FDOC_POST_YR NUMBER(4)
, FDOC_POST_PRD_CD VARCHAR2(3)
, CONSTRAINT FP_DISTRIB_DOC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_DISTRIB_DOC_T
ADD CONSTRAINT FP_DISTRIB_DOC_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- FP_DV_ACH_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_DV_ACH_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_DV_ACH_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_DV_ACH_T
(
DV_ACH_PRFL_NBR VARCHAR2(3)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, DV_PMT_MTHD_CD VARCHAR2(1)
, DV_BNK_NM VARCHAR2(40)
, DV_BNK_RTNG_NBR VARCHAR2(9)
, DV_BNK_CTY_NM VARCHAR2(37)
, DV_BNK_ST_CD VARCHAR2(2)
, DV_BNK_CNTRY_NM VARCHAR2(40)
, DV_ATTN_LN_TXT VARCHAR2(80)
, DV_ADDL_WIRE_TXT VARCHAR2(120)
, DV_PAYEE_ACCT_NBR VARCHAR2(40)
, DV_PAYEE_ACCT_NM VARCHAR2(123)
, DV_PAYEE_ACCT_TYP_CD VARCHAR2(1)
, DV_WIRE_TRNFR_FEE_WVR_IND CHAR(1)
, CONSTRAINT FP_DV_ACH_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_DV_ACH_T
ADD CONSTRAINT FP_DV_ACH_TP1
PRIMARY KEY (DV_ACH_PRFL_NBR)
/
-----------------------------------------------------------------------------
-- FP_DV_DIEM_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_DV_DIEM_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_DV_DIEM_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_DV_DIEM_T
(
UNIV_FISCAL_YR NUMBER(4)
, DV_DIEM_CNTRY_NM VARCHAR2(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, DV_DIEM_RT NUMBER(19,2)
, DV_DIEM_CNTRY_TXT VARCHAR2(255)
, CONSTRAINT FP_DV_DIEM_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_DV_DIEM_T
ADD CONSTRAINT FP_DV_DIEM_TP1
PRIMARY KEY (UNIV_FISCAL_YR,DV_DIEM_CNTRY_NM)
/
-----------------------------------------------------------------------------
-- FP_DV_DOC_LOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_DV_DOC_LOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_DV_DOC_LOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_DV_DOC_LOC_T
(
DV_DOC_LOC_CD VARCHAR2(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, DV_DOC_LOC_NM VARCHAR2(25)
, DV_DOC_LOC_ADDR VARCHAR2(255)
, ROW_ACTV_IND VARCHAR2(1) default 'Y' NOT NULL
, CONSTRAINT FP_DV_DOC_LOC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_DV_DOC_LOC_T
ADD CONSTRAINT FP_DV_DOC_LOC_TP1
PRIMARY KEY (DV_DOC_LOC_CD)
/
-----------------------------------------------------------------------------
-- FP_DV_DOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_DV_DOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_DV_DOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_DV_DOC_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_NXT_LINE_NBR NUMBER(7)
, FDOC_NXT_REG_NBR NUMBER(7)
, DV_CNTCT_PRSN_NM VARCHAR2(123)
, DV_CNTCT_PHN_NBR VARCHAR2(20)
, DV_CNTCT_EMAIL_ID VARCHAR2(50)
, FDOC_POST_YR NUMBER(4)
, FDOC_POST_PRD_CD VARCHAR2(2)
, DV_DUE_DT DATE
, DV_ATTCH_IND CHAR(1)
, DV_SPCL_HANDLG_IND CHAR(1)
, DV_CHK_TOT_AMT NUMBER(19,2)
, DV_FRGN_CRNCY_IND CHAR(1)
, DV_DOC_LOC_CD VARCHAR2(2)
, DV_CHK_STUB_TXT VARCHAR2(1400)
, DV_CHKSTUBOVFL_IND CHAR(1)
, CAMPUS_CD VARCHAR2(2)
, DV_PAYEE_TXCTRL_CD VARCHAR2(1)
, DV_PAYEE_CHG_IND CHAR(1)
, DV_CHK_NBR VARCHAR2(6)
, DV_CHK_DT DATE
, DV_W9_CMPLT_IND CHAR(1)
, DV_PMT_MTHD_CD VARCHAR2(1)
, DV_PAYEE_TYP_CD VARCHAR2(1)
, DV_EXTRT_DT DATE
, DV_PD_DT DATE
, DV_CNCL_DT DATE
, DV_BNK_CD VARCHAR2(4)
, DV_PDP_BNK_CD VARCHAR2(4)
, DV_EXCPT_IND VARCHAR2(1) default 'N' NOT NULL
, IMD_PMT_IND VARCHAR2(1) default 'N'
, DV_PMT_MTHD_ID NUMBER(10)
, INV_NO VARCHAR2(10) NOT NULL
, CONSTRAINT FP_DV_DOC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_DV_DOC_T
ADD CONSTRAINT FP_DV_DOC_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- FP_DV_EXP_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_DV_EXP_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_DV_EXP_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_DV_EXP_TYP_T
(
DV_EXP_CD VARCHAR2(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, DV_EXP_NM VARCHAR2(25)
, DV_EXP_PRPY_IND CHAR(1)
, ROW_ACTV_IND VARCHAR2(1) default 'Y' NOT NULL
, CONSTRAINT FP_DV_EXP_TYP_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_DV_EXP_TYP_T
ADD CONSTRAINT FP_DV_EXP_TYP_TP1
PRIMARY KEY (DV_EXP_CD)
/
-----------------------------------------------------------------------------
-- FP_DV_MLG_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_DV_MLG_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_DV_MLG_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_DV_MLG_T
(
DV_MLG_EFF_DT DATE
, DV_MLG_LMT_AMT NUMBER(7)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, DV_MLG_RT NUMBER(19,4)
, CONSTRAINT FP_DV_MLG_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_DV_MLG_T
ADD CONSTRAINT FP_DV_MLG_TP1
PRIMARY KEY (DV_MLG_EFF_DT,DV_MLG_LMT_AMT)
/
-----------------------------------------------------------------------------
-- FP_DV_NONEMP_EXP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_DV_NONEMP_EXP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_DV_NONEMP_EXP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_DV_NONEMP_EXP_T
(
FDOC_NBR VARCHAR2(14)
, FDOC_LINE_NBR NUMBER(7)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, DV_EXP_CD VARCHAR2(2)
, DV_EXP_CO_NM VARCHAR2(40)
, DV_EXP_AMT NUMBER(19,2)
, CONSTRAINT FP_DV_NONEMP_EXP_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_DV_NONEMP_EXP_T
ADD CONSTRAINT FP_DV_NONEMP_EXP_TP1
PRIMARY KEY (FDOC_NBR,FDOC_LINE_NBR)
/
-----------------------------------------------------------------------------
-- FP_DV_NONEM_TRVL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_DV_NONEM_TRVL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_DV_NONEM_TRVL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_DV_NONEM_TRVL_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, DV_TRVLFROM_CTY_NM VARCHAR2(40)
, DV_TRVL_FROM_ST_CD VARCHAR2(2)
, DV_TRVL_TO_CTY_NM VARCHAR2(40)
, DV_TRVL_TO_ST_CD VARCHAR2(2)
, DV_DIEM_STRT_TS DATE
, DV_DIEM_END_TS DATE
, DV_DIEM_CALC_AMT NUMBER(19,2)
, DV_DIEM_ACTL_AMT NUMBER(19,2)
, DV_DIEM_CHG_TXT VARCHAR2(200)
, DV_SRVC_PRFRM_DESC VARCHAR2(50)
, DV_SRVC_LOC_NM VARCHAR2(40)
, DV_SRVC_EMPR_NM VARCHAR2(40)
, DV_AUTOFROM_CTY_NM VARCHAR2(40)
, DV_AUTO_FROM_ST_CD VARCHAR2(2)
, DV_AUTO_TO_CTY_NM VARCHAR2(40)
, DV_AUTO_TO_ST_CD VARCHAR2(2)
, DV_AUTO_RNDTRP_IND CHAR(1)
, DV_PRSNCAR_MLG_AMT NUMBER(7)
, DV_PRSNL_CAR_RT NUMBER(19,2)
, DV_PRSNL_CAR_AMT NUMBER(19,2)
, DV_EXCPN_IND CHAR(1)
, FDOC_NXT_LINE_NBR NUMBER(7)
, DV_NONEMP_TRVLR_NM VARCHAR2(123)
, DV_DIEM_RT NUMBER(19,2)
, DV_DIEM_CTGRY_NM VARCHAR2(10)
, DV_MLG_CALC_AMT NUMBER(19,2)
, DV_TRVL_FRM_CNTRY_CD VARCHAR2(2)
, DV_TRVL_TO_CNTRY_CD VARCHAR2(2)
, CONSTRAINT FP_DV_NONEM_TRVL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_DV_NONEM_TRVL_T
ADD CONSTRAINT FP_DV_NONEM_TRVL_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- FP_DV_NRA_TAX_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_DV_NRA_TAX_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_DV_NRA_TAX_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_DV_NRA_TAX_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FED_INC_TAX_PCT NUMBER(5,2)
, ST_INC_TAX_PCT NUMBER(5,2)
, INC_CLS_CD VARCHAR2(2)
, POSTAL_CNTRY_CD VARCHAR2(2)
, INC_TAX_TRTY_EXMPT_IND CHAR(1)
, FRGN_SRC_INC_IND CHAR(1)
, INC_TAX_GRS_UP_IND CHAR(1)
, FS_REF_ORIGIN_CD VARCHAR2(2)
, FDOC_REF_NBR VARCHAR2(14)
, FDOC_ACCTG_LN_TXT VARCHAR2(100)
, SPCL_W4_INC_AMT NUMBER(19,2)
, USAID_DIEM_IND VARCHAR2(1)
, INC_TAX_EXMPT_CD_OTHR_IND VARCHAR2(1)
, NQI_CUST_TAX_ID VARCHAR2(50)
, CONSTRAINT FP_DV_NRA_TAX_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_DV_NRA_TAX_T
ADD CONSTRAINT FP_DV_NRA_TAX_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- FP_DV_PAYEE_DTL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_DV_PAYEE_DTL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_DV_PAYEE_DTL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_DV_PAYEE_DTL_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, DV_PMT_REAS_CD VARCHAR2(1)
, DV_ALIEN_PMT_IND CHAR(1)
, DV_PAYEE_ID_NBR VARCHAR2(21)
, DV_PAYEE_PRSN_NM VARCHAR2(123)
, DV_PAYEE_LN1_ADDR VARCHAR2(45)
, DV_PAYEE_LN2_ADDR VARCHAR2(45)
, DV_PAYEE_CTY_NM VARCHAR2(37)
, DV_PAYEE_ST_CD VARCHAR2(2)
, DV_PAYEE_ZIP_CD VARCHAR2(20)
, DV_RMT_PRSN_NM VARCHAR2(123)
, DV_RMT_LN1_ADDR VARCHAR2(45)
, DV_RMT_LN2_ADDR VARCHAR2(45)
, DV_RMT_CTY_NM VARCHAR2(37)
, DV_RMT_ST_CD VARCHAR2(2)
, DV_RMT_ZIP_CD VARCHAR2(20)
, DV_PAYEE_EMP_IND CHAR(1)
, DV_PAYEE_CNTRY_CD VARCHAR2(2)
, DV_RMT_CNTRY_CD VARCHAR2(2)
, DV_PAYEE_TYP_CD VARCHAR2(1)
, CONSTRAINT FP_DV_PAYEE_DTL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_DV_PAYEE_DTL_T
ADD CONSTRAINT FP_DV_PAYEE_DTL_TP1
PRIMARY KEY (FDOC_NBR)
/
CREATE INDEX FP_DV_PAYEE_DTL_TI2
ON FP_DV_PAYEE_DTL_T
(DV_PAYEE_ID_NBR)
/
-----------------------------------------------------------------------------
-- FP_DV_PMT_REAS_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_DV_PMT_REAS_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_DV_PMT_REAS_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_DV_PMT_REAS_T
(
DV_PMT_REAS_CD VARCHAR2(1)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, DV_PMT_REAS_NM VARCHAR2(40)
, DV_PMT_REAS_DESC VARCHAR2(2500)
, DV_PMT_REAS_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT FP_DV_PMT_REAS_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_DV_PMT_REAS_T
ADD CONSTRAINT FP_DV_PMT_REAS_TP1
PRIMARY KEY (DV_PMT_REAS_CD)
/
-----------------------------------------------------------------------------
-- FP_DV_PRECNF_REG_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_DV_PRECNF_REG_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_DV_PRECNF_REG_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_DV_PRECNF_REG_T
(
FDOC_NBR VARCHAR2(14)
, FDOC_LINE_NBR NUMBER(7)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, DV_PRECONF_DEPT_CD VARCHAR2(4)
, DV_CONF_RGSTRNT_NM VARCHAR2(123)
, DV_PRECONF_RQST_NBR VARCHAR2(6)
, DV_EXP_AMT NUMBER(19,2)
, CONSTRAINT FP_DV_PRECNF_REG_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_DV_PRECNF_REG_T
ADD CONSTRAINT FP_DV_PRECNF_REG_TP1
PRIMARY KEY (FDOC_NBR,FDOC_LINE_NBR)
/
-----------------------------------------------------------------------------
-- FP_DV_PRE_CONF_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_DV_PRE_CONF_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_DV_PRE_CONF_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_DV_PRE_CONF_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, DV_CONF_DEST_NM VARCHAR2(40)
, DV_CONF_STRT_DT DATE
, DV_CONF_END_DT DATE
, DV_CONF_TOT_AMT NUMBER(19,2)
, DV_EXP_CD VARCHAR2(2)
, CONSTRAINT FP_DV_PRE_CONF_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_DV_PRE_CONF_T
ADD CONSTRAINT FP_DV_PRE_CONF_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- FP_DV_TRVL_CO_NM_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_DV_TRVL_CO_NM_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_DV_TRVL_CO_NM_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_DV_TRVL_CO_NM_T
(
DV_EXP_CD VARCHAR2(2)
, DV_EXP_CO_NM VARCHAR2(40)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ROW_ACTV_IND VARCHAR2(1) default 'Y' NOT NULL
, CONSTRAINT FP_DV_TRVL_CO_NM_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_DV_TRVL_CO_NM_T
ADD CONSTRAINT FP_DV_TRVL_CO_NM_TP1
PRIMARY KEY (DV_EXP_CD,DV_EXP_CO_NM)
/
-----------------------------------------------------------------------------
-- FP_DV_WIRE_CHRG_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_DV_WIRE_CHRG_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_DV_WIRE_CHRG_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_DV_WIRE_CHRG_T
(
UNIV_FISCAL_YR NUMBER(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, INC_FIN_OBJ_CD VARCHAR2(4)
, EXP_FIN_OBJ_CD VARCHAR2(4)
, DV_DOMSTC_CHG_AMT NUMBER(19,2)
, DV_FRGN_CHRG_AMT NUMBER(19,2)
, CONSTRAINT FP_DV_WIRE_CHRG_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_DV_WIRE_CHRG_T
ADD CONSTRAINT FP_DV_WIRE_CHRG_TP1
PRIMARY KEY (UNIV_FISCAL_YR)
/
-----------------------------------------------------------------------------
-- FP_DV_WIRE_TRNFR_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_DV_WIRE_TRNFR_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_DV_WIRE_TRNFR_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_DV_WIRE_TRNFR_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, DV_BNK_NM VARCHAR2(40)
, DV_BNK_RTNG_NBR VARCHAR2(9)
, DV_BNK_CTY_NM VARCHAR2(37)
, DV_BNK_ST_CD VARCHAR2(2)
, DV_ATTN_LN_TXT VARCHAR2(80)
, DV_ADDL_WIRE_TXT VARCHAR2(120)
, DV_PAYEE_ACCT_NBR VARCHAR2(4000)
, DV_CRNCY_TYP_NM VARCHAR2(20)
, DV_CRNCY_TYP_CD VARCHAR2(1)
, DV_WIRE_TRNFR_FEE_WVR_IND CHAR(1)
, DV_PAYEE_ACCT_NM VARCHAR2(123)
, DV_PAYEE_ACCT_TYP_CD VARCHAR2(1)
, DV_ACH_PRFL_NBR VARCHAR2(3)
, DV_BNK_CNTRY_CD VARCHAR2(2)
, DV_FCRNCY_TYP_NM VARCHAR2(20)
, DV_FCRNCY_TYP_CD VARCHAR2(1)
, CONSTRAINT FP_DV_WIRE_TRNFR_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_DV_WIRE_TRNFR_T
ADD CONSTRAINT FP_DV_WIRE_TRNFR_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- FP_ELCTRNC_PMT_CLM_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_ELCTRNC_PMT_CLM_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_ELCTRNC_PMT_CLM_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_ELCTRNC_PMT_CLM_T
(
FDOC_NBR VARCHAR2(14)
, FDOC_LINE_NBR NUMBER(7)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_REF_NBR VARCHAR2(14)
, FDOC_POST_YR NUMBER(4)
, FDOC_POST_PRD_CD VARCHAR2(2)
, PMT_CLM_STAT_CD VARCHAR2(1)
, CONSTRAINT FP_ELCTRNC_PMT_CLM_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_ELCTRNC_PMT_CLM_T
ADD CONSTRAINT FP_ELCTRNC_PMT_CLM_TP1
PRIMARY KEY (FDOC_NBR,FDOC_LINE_NBR)
/
CREATE INDEX FP_ELCTRNC_PMT_CLM_TI2
ON FP_ELCTRNC_PMT_CLM_T
(FDOC_POST_YR, FDOC_POST_PRD_CD)
/
-----------------------------------------------------------------------------
-- FP_ERROR_COR_DOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_ERROR_COR_DOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_ERROR_COR_DOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_ERROR_COR_DOC_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_NXT_FRM_NBR NUMBER(7)
, FDOC_NXT_TO_NBR NUMBER(7)
, FDOC_POST_YR NUMBER(4)
, FDOC_POST_PRD_CD VARCHAR2(2)
, CONSTRAINT FP_ERROR_COR_DOC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_ERROR_COR_DOC_T
ADD CONSTRAINT FP_ERROR_COR_DOC_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- FP_FND_TRNFR_DOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_FND_TRNFR_DOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_FND_TRNFR_DOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_FND_TRNFR_DOC_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_NXT_FRM_NBR NUMBER(7)
, FDOC_NXT_TO_NBR NUMBER(7)
, FDOC_POST_YR NUMBER(4)
, FDOC_POST_PRD_CD VARCHAR2(2)
, CONSTRAINT FP_FND_TRNFR_DOC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_FND_TRNFR_DOC_T
ADD CONSTRAINT FP_FND_TRNFR_DOC_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- FP_FSCL_YR_CTRL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_FSCL_YR_CTRL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_FSCL_YR_CTRL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_FSCL_YR_CTRL_T
(
UNIV_FISCAL_YR NUMBER(4)
, FS_FUNC_CTRL_CD VARCHAR2(6)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FS_FUNC_ACTIVE_IND VARCHAR2(1)
, CONSTRAINT FP_FSCL_YR_CTRL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_FSCL_YR_CTRL_T
ADD CONSTRAINT FP_FSCL_YR_CTRL_TP1
PRIMARY KEY (UNIV_FISCAL_YR,FS_FUNC_CTRL_CD)
/
-----------------------------------------------------------------------------
-- FP_FUNC_CTRL_CD_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_FUNC_CTRL_CD_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_FUNC_CTRL_CD_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_FUNC_CTRL_CD_T
(
FS_FUNC_CTRL_CD VARCHAR2(6)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FS_FUNC_DFLT_IND VARCHAR2(1)
, FS_FUNC_DESC VARCHAR2(40)
, CONSTRAINT FP_FUNC_CTRL_CD_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_FUNC_CTRL_CD_T
ADD CONSTRAINT FP_FUNC_CTRL_CD_TP1
PRIMARY KEY (FS_FUNC_CTRL_CD)
/
-----------------------------------------------------------------------------
-- FP_ICR_ADJ_DOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_ICR_ADJ_DOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_ICR_ADJ_DOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_ICR_ADJ_DOC_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_NXT_FRM_NBR NUMBER(7)
, FDOC_NXT_TO_NBR NUMBER(7)
, FDOC_POST_YR NUMBER(4)
, FDOC_POST_PRD_CD VARCHAR2(3)
, CONSTRAINT FP_ICR_ADJ_DOC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_ICR_ADJ_DOC_T
ADD CONSTRAINT FP_ICR_ADJ_DOC_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- FP_INC_CLS_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_INC_CLS_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_INC_CLS_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_INC_CLS_T
(
INC_CLS_CD VARCHAR2(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, INC_CLS_NM VARCHAR2(40)
, ROW_ACTV_IND VARCHAR2(1) default 'Y' NOT NULL
, CONSTRAINT FP_INC_CLS_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_INC_CLS_T
ADD CONSTRAINT FP_INC_CLS_TP1
PRIMARY KEY (INC_CLS_CD)
/
-----------------------------------------------------------------------------
-- FP_INTERIM1_CONS_MT
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_INTERIM1_CONS_MT';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_INTERIM1_CONS_MT CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_INTERIM1_CONS_MT
(
SESID VARCHAR2(36)
, UNIV_FISCAL_YR NUMBER(4)
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_OBJECT_CD VARCHAR2(4)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, VER_NBR NUMBER(8) default 1 NOT NULL
, CURR_BDLN_BAL_AMT NUMBER(19,2)
, ACLN_ACTLS_BAL_AMT NUMBER(19,2)
, ACLN_ENCUM_BAL_AMT NUMBER(19,2)
, TIMESTAMP DATE
, FIN_REPORT_SORT_CD VARCHAR2(1)
, FIN_OBJ_TYP_CD VARCHAR2(2)
)
/
ALTER TABLE FP_INTERIM1_CONS_MT
ADD CONSTRAINT FP_INTERIM1_CONS_MTP1
PRIMARY KEY (SESID,UNIV_FISCAL_YR,FIN_COA_CD,ACCOUNT_NBR,SUB_ACCT_NBR,FIN_OBJECT_CD,FIN_SUB_OBJ_CD)
/
-----------------------------------------------------------------------------
-- FP_INTERIM1_LEVEL_MT
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_INTERIM1_LEVEL_MT';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_INTERIM1_LEVEL_MT CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_INTERIM1_LEVEL_MT
(
SESID VARCHAR2(36)
, UNIV_FISCAL_YR NUMBER(4)
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_OBJECT_CD VARCHAR2(4)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, VER_NBR NUMBER(8) default 1 NOT NULL
, CURR_BDLN_BAL_AMT NUMBER(19,2)
, ACLN_ACTLS_BAL_AMT NUMBER(19,2)
, ACLN_ENCUM_BAL_AMT NUMBER(19,2)
, TIMESTAMP DATE
, FIN_REPORT_SORT_CD VARCHAR2(2)
, FIN_OBJ_LEVEL_CD VARCHAR2(4)
)
/
ALTER TABLE FP_INTERIM1_LEVEL_MT
ADD CONSTRAINT FP_INTERIM1_LEVEL_MTP1
PRIMARY KEY (SESID,UNIV_FISCAL_YR,FIN_COA_CD,ACCOUNT_NBR,SUB_ACCT_NBR,FIN_OBJECT_CD,FIN_SUB_OBJ_CD)
/
-----------------------------------------------------------------------------
-- FP_INTERIM1_OBJ_MT
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_INTERIM1_OBJ_MT';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_INTERIM1_OBJ_MT CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_INTERIM1_OBJ_MT
(
SESID VARCHAR2(36)
, UNIV_FISCAL_YR NUMBER(4)
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_OBJECT_CD VARCHAR2(4)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, VER_NBR NUMBER(8) default 1 NOT NULL
, CURR_BDLN_BAL_AMT NUMBER(19,2)
, ACLN_ACTLS_BAL_AMT NUMBER(19,2)
, ACLN_ENCUM_BAL_AMT NUMBER(19,2)
, TIMESTAMP DATE
)
/
ALTER TABLE FP_INTERIM1_OBJ_MT
ADD CONSTRAINT FP_INTERIM1_OBJ_MTP1
PRIMARY KEY (SESID,UNIV_FISCAL_YR,FIN_COA_CD,ACCOUNT_NBR,SUB_ACCT_NBR,FIN_OBJECT_CD,FIN_SUB_OBJ_CD)
/
-----------------------------------------------------------------------------
-- FP_INTERIM2_CONS_MT
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_INTERIM2_CONS_MT';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_INTERIM2_CONS_MT CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_INTERIM2_CONS_MT
(
SESID VARCHAR2(36)
, UNIV_FISCAL_YR NUMBER(4)
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_OBJECT_CD VARCHAR2(4)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, VER_NBR NUMBER(8) default 1 NOT NULL
, CURR_BDLN_BAL_AMT NUMBER(19,2)
, ACLN_ACTLS_BAL_AMT NUMBER(19,2)
, ACLN_ENCUM_BAL_AMT NUMBER(19,2)
, TIMESTAMP DATE
, FIN_REPORT_SORT_CD VARCHAR2(1)
, FIN_OBJ_TYP_CD VARCHAR2(2)
, CONS_FIN_REPORT_SORT_CD VARCHAR2(2)
, FIN_CONS_OBJ_CD VARCHAR2(4)
, ACCTG_CTGRY_CD VARCHAR2(2)
)
/
ALTER TABLE FP_INTERIM2_CONS_MT
ADD CONSTRAINT FP_INTERIM2_CONS_MTP1
PRIMARY KEY (SESID,UNIV_FISCAL_YR,FIN_COA_CD,ACCOUNT_NBR,SUB_ACCT_NBR,FIN_OBJECT_CD,FIN_SUB_OBJ_CD)
/
-----------------------------------------------------------------------------
-- FP_INTERIM2_LEVEL_MT
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_INTERIM2_LEVEL_MT';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_INTERIM2_LEVEL_MT CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_INTERIM2_LEVEL_MT
(
SESID VARCHAR2(36)
, UNIV_FISCAL_YR NUMBER(4)
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_OBJECT_CD VARCHAR2(4)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, CURR_BDLN_BAL_AMT NUMBER(19,2)
, ACLN_ACTLS_BAL_AMT NUMBER(19,2)
, ACLN_ENCUM_BAL_AMT NUMBER(19,2)
, TIMESTAMP DATE
, FIN_REPORT_SORT_CD VARCHAR2(2)
, FIN_OBJ_LEVEL_CD VARCHAR2(4)
, ACCTG_CTGRY_CD VARCHAR2(2)
)
/
ALTER TABLE FP_INTERIM2_LEVEL_MT
ADD CONSTRAINT FP_INTERIM2_LEVEL_MTP1
PRIMARY KEY (SESID,UNIV_FISCAL_YR,FIN_COA_CD,ACCOUNT_NBR,SUB_ACCT_NBR,FIN_OBJECT_CD,FIN_SUB_OBJ_CD)
/
-----------------------------------------------------------------------------
-- FP_INTERIM2_OBJ_MT
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_INTERIM2_OBJ_MT';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_INTERIM2_OBJ_MT CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_INTERIM2_OBJ_MT
(
SESID VARCHAR2(36)
, UNIV_FISCAL_YR NUMBER(4)
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_OBJECT_CD VARCHAR2(4)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, CURR_BDLN_BAL_AMT NUMBER(19,2)
, ACLN_ACTLS_BAL_AMT NUMBER(19,2)
, ACLN_ENCUM_BAL_AMT NUMBER(19,2)
, TIMESTAMP DATE
, FIN_REPORT_SORT_CD VARCHAR2(2)
, ACCTG_CTGRY_CD VARCHAR2(2)
)
/
ALTER TABLE FP_INTERIM2_OBJ_MT
ADD CONSTRAINT FP_INTERIM2_OBJ_MTP1
PRIMARY KEY (SESID,UNIV_FISCAL_YR,FIN_COA_CD,ACCOUNT_NBR,SUB_ACCT_NBR,FIN_OBJECT_CD,FIN_SUB_OBJ_CD)
/
-----------------------------------------------------------------------------
-- FP_INT_BILL_DOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_INT_BILL_DOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_INT_BILL_DOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_INT_BILL_DOC_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_NXT_EXP_NBR NUMBER(7)
, FDOC_NXT_INC_NBR NUMBER(7)
, FDOC_NXT_ITM_NBR NUMBER(7)
, FDOC_POST_YR NUMBER(4)
, FDOC_POST_PRD_CD VARCHAR2(3)
, CONSTRAINT FP_INT_BILL_DOC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_INT_BILL_DOC_T
ADD CONSTRAINT FP_INT_BILL_DOC_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- FP_INT_BILL_ITM_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_INT_BILL_ITM_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_INT_BILL_ITM_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_INT_BILL_ITM_T
(
FDOC_NBR VARCHAR2(14)
, FDOC_ITM_NBR NUMBER(7)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_ITM_STCK_NBR VARCHAR2(9)
, FDOC_ITM_STCK_DESC VARCHAR2(40)
, FDOC_ITM_SRVC_DT DATE
, FDOC_ITM_QTY NUMBER(7,2)
, FDOC_ITM_UNIT_AMT NUMBER(19,2)
, FDOC_UNIT_MSR_CD VARCHAR2(2)
, CONSTRAINT FP_INT_BILL_ITM_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_INT_BILL_ITM_T
ADD CONSTRAINT FP_INT_BILL_ITM_TP1
PRIMARY KEY (FDOC_NBR,FDOC_ITM_NBR)
/
-----------------------------------------------------------------------------
-- FP_JRNL_VCHR_DOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_JRNL_VCHR_DOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_JRNL_VCHR_DOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_JRNL_VCHR_DOC_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_NXT_LINE_NBR NUMBER(7)
, FDOC_POST_YR NUMBER(4)
, FDOC_POST_PRD_CD VARCHAR2(2)
, FDOC_REVERSAL_DT DATE
, FIN_BALANCE_TYP_CD VARCHAR2(2)
, CONSTRAINT FP_JRNL_VCHR_DOC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_JRNL_VCHR_DOC_T
ADD CONSTRAINT FP_JRNL_VCHR_DOC_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- FP_JV_ACCT_LINES_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_JV_ACCT_LINES_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_JV_ACCT_LINES_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_JV_ACCT_LINES_T
(
FDOC_NBR VARCHAR2(14)
, FDOC_LINE_NBR NUMBER(7)
, FDOC_LN_TYP_CD VARCHAR2(1)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, FDOC_POST_YR NUMBER(4)
, FIN_OBJECT_CD VARCHAR2(4)
, FIN_BALANCE_TYP_CD VARCHAR2(2)
, FDOC_LINE_AMT NUMBER(19,2)
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, PROJECT_CD VARCHAR2(10)
, ORG_REFERENCE_ID VARCHAR2(8)
, FS_REF_ORIGIN_CD VARCHAR2(2)
, FDOC_REF_NBR VARCHAR2(14)
, FDOC_REF_TYP_CD VARCHAR2(8)
, FDOC_OVERRIDE_CD VARCHAR2(100)
, FDOC_LINE_DESC VARCHAR2(40)
, FDOC_LINE_DBCR_CD VARCHAR2(1)
, TRN_ENCUM_UPDT_CD VARCHAR2(1)
, FIN_OBJ_TYP_CD VARCHAR2(2)
)
/
ALTER TABLE FP_JV_ACCT_LINES_T
ADD CONSTRAINT FP_JV_ACCT_LINES_TP1
PRIMARY KEY (FDOC_NBR,FDOC_LINE_NBR,FDOC_LN_TYP_CD)
/
-----------------------------------------------------------------------------
-- FP_MOTD_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_MOTD_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_MOTD_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_MOTD_T
(
FS_ORIGIN_CD VARCHAR2(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FS_MOTD_TXT VARCHAR2(2000)
, CONSTRAINT FP_MOTD_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_MOTD_T
ADD CONSTRAINT FP_MOTD_TP1
PRIMARY KEY (FS_ORIGIN_CD)
/
-----------------------------------------------------------------------------
-- FP_NCHK_DSBRSDOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_NCHK_DSBRSDOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_NCHK_DSBRSDOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_NCHK_DSBRSDOC_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_NXT_LINE_NBR NUMBER(7)
, FDOC_POST_YR NUMBER(4)
, FDOC_POST_PRD_CD VARCHAR2(2)
, FDOC_BNK_CD VARCHAR2(4)
, CONSTRAINT FP_NCHK_DSBRSDOC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_NCHK_DSBRSDOC_T
ADD CONSTRAINT FP_NCHK_DSBRSDOC_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- FP_NRA_TAX_PCT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_NRA_TAX_PCT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_NRA_TAX_PCT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_NRA_TAX_PCT_T
(
INC_CLS_CD VARCHAR2(2)
, INC_TAX_TYP_CD VARCHAR2(1)
, INC_TAX_PCT NUMBER(5,2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ROW_ACTV_IND VARCHAR2(1) default 'Y' NOT NULL
, CONSTRAINT FP_NRA_TAX_PCT_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_NRA_TAX_PCT_T
ADD CONSTRAINT FP_NRA_TAX_PCT_TP1
PRIMARY KEY (INC_CLS_CD,INC_TAX_TYP_CD,INC_TAX_PCT)
/
-----------------------------------------------------------------------------
-- FP_OFST_ACCT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_OFST_ACCT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_OFST_ACCT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_OFST_ACCT_T
(
FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, FIN_OFST_OBJ_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FIN_OFST_COA_CD VARCHAR2(2)
, FIN_OFST_ACCT_NBR VARCHAR2(7)
, ROW_ACTV_IND VARCHAR2(1) default 'Y' NOT NULL
, CONSTRAINT FP_OFST_ACCT_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_OFST_ACCT_T
ADD CONSTRAINT FP_OFST_ACCT_TP1
PRIMARY KEY (FIN_COA_CD,ACCOUNT_NBR,FIN_OFST_OBJ_CD)
/
-----------------------------------------------------------------------------
-- FP_PRCRMNT_ACCT_LINES_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_PRCRMNT_ACCT_LINES_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_PRCRMNT_ACCT_LINES_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_PRCRMNT_ACCT_LINES_T
(
FDOC_NBR VARCHAR2(14)
, FDOC_TRN_LN_NBR NUMBER(7)
, FDOC_LINE_NBR NUMBER(7)
, FDOC_LN_TYP_CD VARCHAR2(1)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, FDOC_POST_YR NUMBER(4)
, FIN_OBJECT_CD VARCHAR2(4)
, FIN_BALANCE_TYP_CD VARCHAR2(2)
, FDOC_LINE_AMT NUMBER(19,2)
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, PROJECT_CD VARCHAR2(10)
, ORG_REFERENCE_ID VARCHAR2(8)
, FDOC_OVERRIDE_CD VARCHAR2(100)
, FDOC_LINE_DESC VARCHAR2(40)
, CONSTRAINT FP_PRCRMNT_ACCT_LINES_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_PRCRMNT_ACCT_LINES_T
ADD CONSTRAINT FP_PRCRMNT_ACCT_LINES_TP1
PRIMARY KEY (FDOC_NBR,FDOC_TRN_LN_NBR,FDOC_LINE_NBR,FDOC_LN_TYP_CD)
/
-----------------------------------------------------------------------------
-- FP_PRCRMNT_CARD_DFLT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_PRCRMNT_CARD_DFLT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_PRCRMNT_CARD_DFLT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_PRCRMNT_CARD_DFLT_T
(
CC_NBR VARCHAR2(16)
, VER_NBR NUMBER(8) default 1 NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
, CARD_HLDR_NM VARCHAR2(123)
, CARD_HLDR_ALTRNT_NM VARCHAR2(123)
, CARD_HLDR_LN1_ADDR VARCHAR2(45)
, CARD_HLDR_LN2_ADDR VARCHAR2(45)
, CARD_HLDR_CTY_NM VARCHAR2(45)
, CARD_HLDR_ST_CD VARCHAR2(2)
, CARD_HLDR_ZIP_CD VARCHAR2(20)
, CARD_HLDR_WRK_PHN_NBR VARCHAR2(10)
, CARD_LMT NUMBER(19,2)
, CARD_CYCLE_AMT_LMT NUMBER(19,2)
, CARD_CYCLE_VOL_LMT NUMBER(19,2)
, CARD_STAT_CD VARCHAR2(2)
, CARD_NTE_TXT VARCHAR2(50)
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_OBJECT_CD VARCHAR2(4)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, PROJECT_CD VARCHAR2(10)
, ROW_ACTV_IND VARCHAR2(1)
, CONSTRAINT FP_PRCRMNT_CARD_DFLT_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_PRCRMNT_CARD_DFLT_T
ADD CONSTRAINT FP_PRCRMNT_CARD_DFLT_TP1
PRIMARY KEY (CC_NBR)
/
-----------------------------------------------------------------------------
-- FP_PRCRMNT_CARD_HLDR_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_PRCRMNT_CARD_HLDR_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_PRCRMNT_CARD_HLDR_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_PRCRMNT_CARD_HLDR_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, TRN_CC_NBR VARCHAR2(4000)
, FDOC_CARD_HLDR_NM VARCHAR2(123)
, FDOC_CARD_HLDR_ALTRNT_NM VARCHAR2(123)
, FDOC_CARD_HLDR_LN1_ADDR VARCHAR2(45)
, FDOC_CARD_HLDR_LN2_ADDR VARCHAR2(45)
, FDOC_CARD_HLDR_CTY_NM VARCHAR2(45)
, FDOC_CARD_HLDR_ST_CD VARCHAR2(2)
, FDOC_CARD_HLDR_ZIP_CD VARCHAR2(20)
, FDOC_CARD_HLDR_WRK_PHN_NBR VARCHAR2(10)
, FDOC_CARD_LMT NUMBER(19,2)
, FDOC_CARD_CYCLE_AMT_LMT NUMBER(19,2)
, FDOC_CARD_CYCLE_VOL_LMT NUMBER(19,2)
, FDOC_CARD_STAT_CD VARCHAR2(2)
, FDOC_CARD_NTE_TXT VARCHAR2(50)
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, SUB_ACCT_NBR VARCHAR2(5)
, CONSTRAINT FP_PRCRMNT_CARD_HLDR_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_PRCRMNT_CARD_HLDR_T
ADD CONSTRAINT FP_PRCRMNT_CARD_HLDR_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- FP_PRCRMNT_CARD_TRN_MT
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_PRCRMNT_CARD_TRN_MT';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_PRCRMNT_CARD_TRN_MT CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_PRCRMNT_CARD_TRN_MT
(
TRN_SEQ_ROW_NBR NUMBER(7)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, TRN_CC_NBR VARCHAR2(16)
, FDOC_TOTAL_AMT NUMBER(19,2)
, TRN_DEBIT_CRDT_CD VARCHAR2(1)
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_OBJECT_CD VARCHAR2(4)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, PROJECT_CD VARCHAR2(10)
, TRN_CYCLE_STRT_DT DATE
, TRN_CYCLE_END_DT DATE
, FDOC_CARD_HLDR_NM VARCHAR2(123)
, TRANSACTION_DT DATE
, TRN_REF_NBR VARCHAR2(23)
, TRN_MCC_CD VARCHAR2(4)
, TRN_POST_DT DATE
, TRN_ORIG_CRNCY_CD VARCHAR2(3)
, TRN_BILL_CRNCY_CD VARCHAR2(3)
, TRN_ORIG_CRNCY_AMT NUMBER(19,2)
, TRN_CRNCY_EXCH_RT NUMBER(10,6)
, TRN_STLMNT_AMT NUMBER(19,2)
, TRN_SALES_TAX_AMT NUMBER(19,2)
, TRN_TAX_EXMPT_IND VARCHAR2(1)
, TRN_PURCH_ID_IND VARCHAR2(1)
, TRN_PURCH_ID_DESC VARCHAR2(25)
, TRN_UNIT_CNTCT_NM VARCHAR2(123)
, TRN_TRVL_AUTH_CD VARCHAR2(50)
, TRN_PT_OF_SALE_CD VARCHAR2(25)
, VNDR_NM VARCHAR2(45)
, VNDR_LN1_ADDR VARCHAR2(45)
, VNDR_LN2_ADDR VARCHAR2(45)
, VNDR_CTY_NM VARCHAR2(45)
, VNDR_ST_CD VARCHAR2(2)
, VNDR_ZIP_CD VARCHAR2(20)
, VNDR_ORD_NBR VARCHAR2(12)
, VISA_VNDR_ID VARCHAR2(16)
, FDOC_CARD_HLDR_ALTRNT_NM VARCHAR2(123)
, FDOC_CARD_HLDR_LN1_ADDR VARCHAR2(45)
, FDOC_CARD_HLDR_LN2_ADDR VARCHAR2(45)
, FDOC_CARD_HLDR_CTY_NM VARCHAR2(45)
, FDOC_CARD_HLDR_ST_CD VARCHAR2(2)
, FDOC_CARD_HLDR_ZIP_CD VARCHAR2(20)
, FDOC_CARD_HLDR_WRK_PHN_NBR VARCHAR2(10)
, FDOC_CARD_LMT NUMBER(19,2)
, FDOC_CARD_CYCLE_AMT_LMT NUMBER(19,2)
, FDOC_CARD_CYCLE_VOL_LMT NUMBER(19,2)
, FDOC_CARD_STAT_CD VARCHAR2(2)
, FDOC_CARD_NTE_TXT VARCHAR2(50)
, CONSTRAINT FP_PRCRMNT_CARD_TRN_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_PRCRMNT_CARD_TRN_MT
ADD CONSTRAINT FP_PRCRMNT_CARD_TRN_MTP1
PRIMARY KEY (TRN_SEQ_ROW_NBR)
/
-----------------------------------------------------------------------------
-- FP_PRCRMNT_DOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_PRCRMNT_DOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_PRCRMNT_DOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_PRCRMNT_DOC_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_NXT_LINE_NBR NUMBER(7)
, CONSTRAINT FP_PRCRMNT_DOC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_PRCRMNT_DOC_T
ADD CONSTRAINT FP_PRCRMNT_DOC_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- FP_PRCRMNT_TRN_DTL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_PRCRMNT_TRN_DTL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_PRCRMNT_TRN_DTL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_PRCRMNT_TRN_DTL_T
(
FDOC_NBR VARCHAR2(14)
, FDOC_TRN_LN_NBR NUMBER(7)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, TRANSACTION_DT DATE
, TRN_REF_NBR VARCHAR2(23)
, TRN_POST_DT DATE
, TRN_ORIG_CRNCY_CD VARCHAR2(3)
, TRN_BILL_CRNCY_CD VARCHAR2(3)
, TRN_ORIG_CRNCY_AMT NUMBER(19,2)
, TRN_CRNCY_EXCH_RT NUMBER(10,6)
, TRN_STLMNT_AMT NUMBER(19,2)
, TRN_SALES_TAX_AMT NUMBER(19,2)
, TRN_TAX_EXMPT_IND VARCHAR2(1)
, TRN_PURCH_ID_IND VARCHAR2(1)
, TRN_PURCH_ID_DESC VARCHAR2(25)
, TRN_UNIT_CNTCT_NM VARCHAR2(123)
, TRN_TRVL_AUTH_CD VARCHAR2(50)
, TRN_PT_OF_SALE_CD VARCHAR2(25)
, TRN_CYCLE_STRT_DT DATE
, TRN_CYCLE_END_DT DATE
, TRN_TOT_AMT NUMBER(19,2)
, CONSTRAINT FP_PRCRMNT_TRN_DTL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_PRCRMNT_TRN_DTL_T
ADD CONSTRAINT FP_PRCRMNT_TRN_DTL_TP1
PRIMARY KEY (FDOC_NBR,FDOC_TRN_LN_NBR)
/
-----------------------------------------------------------------------------
-- FP_PRCRMNT_VNDR_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_PRCRMNT_VNDR_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_PRCRMNT_VNDR_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_PRCRMNT_VNDR_T
(
FDOC_NBR VARCHAR2(14)
, FDOC_TRN_LN_NBR NUMBER(7)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, VNDR_NM VARCHAR2(45)
, VNDR_LN1_ADDR VARCHAR2(45)
, VNDR_LN2_ADDR VARCHAR2(45)
, VNDR_CTY_NM VARCHAR2(45)
, VNDR_ST_CD VARCHAR2(2)
, VNDR_ZIP_CD VARCHAR2(20)
, VISA_VNDR_ID VARCHAR2(16)
, VNDR_ORD_NBR VARCHAR2(12)
, TRN_MCC_CD VARCHAR2(4)
, CONSTRAINT FP_PRCRMNT_VNDR_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_PRCRMNT_VNDR_T
ADD CONSTRAINT FP_PRCRMNT_VNDR_TP1
PRIMARY KEY (FDOC_NBR,FDOC_TRN_LN_NBR)
/
-----------------------------------------------------------------------------
-- FP_PRE_ENCUM_DOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_PRE_ENCUM_DOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_PRE_ENCUM_DOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_PRE_ENCUM_DOC_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_POST_YR NUMBER(4)
, FDOC_POST_PRD_CD VARCHAR2(2)
, FDOC_NXT_ENC_NBR NUMBER(7)
, FDOC_REVERSAL_DT DATE
, FDOC_NXT_DIS_NBR NUMBER(7)
, CONSTRAINT FP_PRE_ENCUM_DOC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_PRE_ENCUM_DOC_T
ADD CONSTRAINT FP_PRE_ENCUM_DOC_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- FP_RPT_CD_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_RPT_CD_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_RPT_CD_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_RPT_CD_T
(
FIN_RPT_CHRT_CD VARCHAR2(2)
, FIN_RPT_ORG_CD VARCHAR2(4)
, FIN_RPT_CD VARCHAR2(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FIN_RPT_CD_DESC VARCHAR2(40)
, FIN_REP_CD_MGR_ID VARCHAR2(40)
, FIN_RPTS_TO_RPT_CD VARCHAR2(10)
, ROW_ACTV_IND VARCHAR2(1) default 'Y' NOT NULL
, CONSTRAINT FP_RPT_CD_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_RPT_CD_T
ADD CONSTRAINT FP_RPT_CD_TP1
PRIMARY KEY (FIN_RPT_CHRT_CD,FIN_RPT_ORG_CD,FIN_RPT_CD)
/
-----------------------------------------------------------------------------
-- FP_SALES_TAX_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FP_SALES_TAX_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FP_SALES_TAX_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FP_SALES_TAX_T
(
FDOC_NBR VARCHAR2(14)
, FDOC_LN_TYP_CD VARCHAR2(1)
, FDOC_LINE_NBR NUMBER(7)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, FDOC_GRS_SALES_AMT NUMBER(19,2)
, FDOC_TXBL_SALES_AMT NUMBER(19,2)
, FDOC_SALE_DT DATE
, CONSTRAINT FP_SALES_TAX_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FP_SALES_TAX_T
ADD CONSTRAINT FP_SALES_TAX_TP1
PRIMARY KEY (FDOC_NBR,FDOC_LN_TYP_CD,FDOC_LINE_NBR)
/
-----------------------------------------------------------------------------
-- FS_CLCTR_HDR_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FS_CLCTR_HDR_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FS_CLCTR_HDR_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FS_CLCTR_HDR_T
(
FIN_COA_CD VARCHAR2(2)
, ORG_CD VARCHAR2(4)
, PROC_TRNS_DT DATE
, PROC_BATCH_SEQ_NBR NUMBER(5)
, PROC_TOT_REC_CNT NUMBER(5)
, PROC_TOT_AMT NUMBER(19,2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CAMPUS_CD VARCHAR2(2) NOT NULL
, CNTCT_PRSN_PHN_NBR VARCHAR2(20) NOT NULL
, CNTCT_MAIL_ADDR VARCHAR2(30) NOT NULL
, CNTCT_DEPT_NM VARCHAR2(30) NOT NULL
, CONSTRAINT FS_CLCTR_HDR_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FS_CLCTR_HDR_T
ADD CONSTRAINT FS_CLCTR_HDR_TP1
PRIMARY KEY (FIN_COA_CD,ORG_CD,PROC_TRNS_DT,PROC_BATCH_SEQ_NBR,PROC_TOT_REC_CNT,PROC_TOT_AMT)
/
-----------------------------------------------------------------------------
-- FS_DOC_HEADER_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FS_DOC_HEADER_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FS_DOC_HEADER_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FS_DOC_HEADER_T
(
FDOC_NBR VARCHAR2(14)
, FDOC_STATUS_CD VARCHAR2(2)
, FDOC_TOTAL_AMT NUMBER(19,2)
, FDOC_IN_ERR_NBR VARCHAR2(14)
, TEMP_DOC_FNL_DT DATE
)
/
ALTER TABLE FS_DOC_HEADER_T
ADD CONSTRAINT FS_DOC_HEADER_TP1
PRIMARY KEY (FDOC_NBR)
/
CREATE INDEX FS_DOC_HEADER_TI1
ON FS_DOC_HEADER_T
(FDOC_IN_ERR_NBR)
/
-----------------------------------------------------------------------------
-- FS_HOME_ORIGIN_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FS_HOME_ORIGIN_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FS_HOME_ORIGIN_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FS_HOME_ORIGIN_T
(
FS_HOME_ORIGIN_CD VARCHAR2(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CONSTRAINT FS_HOME_ORIGIN_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FS_HOME_ORIGIN_T
ADD CONSTRAINT FS_HOME_ORIGIN_TP1
PRIMARY KEY (FS_HOME_ORIGIN_CD)
/
-----------------------------------------------------------------------------
-- FS_OPTION_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FS_OPTION_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FS_OPTION_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FS_OPTION_T
(
UNIV_FISCAL_YR NUMBER(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ACT_FIN_BAL_TYP_CD VARCHAR2(2)
, BDGT_CHK_BALTYP_CD VARCHAR2(2)
, BDGT_CHK_OPTN_CD VARCHAR2(1)
, UNIV_FSCYR_STRT_YR NUMBER(4)
, UNIV_FSCYR_STRT_MO VARCHAR2(2)
, FOBJTP_INC_CSH_CD VARCHAR2(2)
, FOBJTP_XPND_EXP_CD VARCHAR2(2)
, FOBJTP_XPNDNEXP_CD VARCHAR2(2)
, FOBJTP_EXPNXPND_CD VARCHAR2(2)
, FOBJ_TYP_ASSET_CD VARCHAR2(2)
, FOBJ_TYP_LBLTY_CD VARCHAR2(2)
, FOBJ_TYP_FNDBAL_CD VARCHAR2(2)
, EXT_ENC_FBALTYP_CD VARCHAR2(2)
, INT_ENC_FBALTYP_CD VARCHAR2(2)
, PRE_ENC_FBALTYP_CD VARCHAR2(2)
, ELIM_FINBAL_TYP_CD VARCHAR2(2)
, FOBJTP_INC_NCSH_CD VARCHAR2(2)
, FOBJTP_CSH_NINC_CD VARCHAR2(2)
, UNIV_FIN_COA_CD VARCHAR2(2)
, UNIV_FISCAL_YR_NM VARCHAR2(10)
, FIN_BEGBALLOAD_IND VARCHAR2(1)
, CSTSHR_ENCUM_FIN_BAL_TYP_CD VARCHAR2(2)
, BASE_BDGT_FIN_BAL_TYP_CD VARCHAR2(2)
, MO_BDGT_FIN_BAL_TYP_CD VARCHAR2(2)
, FIN_OBJECT_TYP_TRNFR_INC_CD VARCHAR2(2)
, FIN_OBJECT_TYP_TRNFR_EXP_CD VARCHAR2(2)
, NMNL_FIN_BAL_TYP_CD VARCHAR2(2)
, CONSTRAINT FS_OPTION_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FS_OPTION_T
ADD CONSTRAINT FS_OPTION_TP1
PRIMARY KEY (UNIV_FISCAL_YR)
/
-----------------------------------------------------------------------------
-- FS_ORIGIN_CODE_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FS_ORIGIN_CODE_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FS_ORIGIN_CODE_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FS_ORIGIN_CODE_T
(
FS_ORIGIN_CD VARCHAR2(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FS_SERVER_NM VARCHAR2(20)
, FS_DATABASE_NM VARCHAR2(15)
, FS_DATABASE_DESC VARCHAR2(40)
, NEXT_CPTLAST_NBR NUMBER(12)
, NEXT_NONCA_NBR NUMBER(12)
, NEXT_CG_AGENCY_NBR VARCHAR2(5)
, NEXT_CG_SUBCNR_NBR VARCHAR2(5)
, NXT_DV_PAYEEID_NBR NUMBER(12)
, NXT_FDOC_ATT_ID NUMBER(12)
, AR_NEXT_CUST_NBR NUMBER(12)
, FDOC_NEXT_ITEM_ID NUMBER(12)
, ROW_ACTV_IND VARCHAR2(1) default 'Y' NOT NULL
, CONSTRAINT FS_ORIGIN_CODE_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FS_ORIGIN_CODE_T
ADD CONSTRAINT FS_ORIGIN_CODE_TP1
PRIMARY KEY (FS_ORIGIN_CD)
/
-----------------------------------------------------------------------------
-- FS_TAX_COUNTY_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FS_TAX_COUNTY_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FS_TAX_COUNTY_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FS_TAX_COUNTY_T
(
POSTAL_CNTRY_CD VARCHAR2(2)
, COUNTY_CD VARCHAR2(10)
, STATE_CD VARCHAR2(2)
, TAX_REGION_CD VARCHAR2(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ACTV_IND VARCHAR2(1)
, CONSTRAINT FS_TAX_COUNTY_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FS_TAX_COUNTY_T
ADD CONSTRAINT FS_TAX_COUNTY_TP1
PRIMARY KEY (POSTAL_CNTRY_CD,COUNTY_CD,STATE_CD,TAX_REGION_CD)
/
-----------------------------------------------------------------------------
-- FS_TAX_POSTAL_CD_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FS_TAX_POSTAL_CD_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FS_TAX_POSTAL_CD_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FS_TAX_POSTAL_CD_T
(
POSTAL_CNTRY_CD VARCHAR2(2)
, POSTAL_CD VARCHAR2(20)
, TAX_REGION_CD VARCHAR2(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ACTV_IND VARCHAR2(1)
, CONSTRAINT FS_TAX_POSTAL_CD_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FS_TAX_POSTAL_CD_T
ADD CONSTRAINT FS_TAX_POSTAL_CD_TP1
PRIMARY KEY (POSTAL_CNTRY_CD,POSTAL_CD,TAX_REGION_CD)
/
-----------------------------------------------------------------------------
-- FS_TAX_REGION_RATE_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FS_TAX_REGION_RATE_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FS_TAX_REGION_RATE_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FS_TAX_REGION_RATE_T
(
TAX_REGION_CD VARCHAR2(10)
, TAX_RATE_EFFECTIVE_DT DATE
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, TAX_RATE NUMBER(9,8)
, CONSTRAINT FS_TAX_DISTRICT_RATE_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FS_TAX_REGION_RATE_T
ADD CONSTRAINT FS_TAX_REGION_RATE_TP1
PRIMARY KEY (TAX_REGION_CD,TAX_RATE_EFFECTIVE_DT)
/
-----------------------------------------------------------------------------
-- FS_TAX_REGION_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FS_TAX_REGION_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FS_TAX_REGION_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FS_TAX_REGION_T
(
TAX_REGION_CD VARCHAR2(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, TAX_REGION_NM VARCHAR2(100)
, TAX_REGION_TYP_CD VARCHAR2(4)
, TAX_REGION_USE_TAX_IND VARCHAR2(1)
, LIAB_ACCT_FIN_COA_CD VARCHAR2(2)
, LIAB_ACCT_ACCT_NBR VARCHAR2(7)
, LIAB_ACCT_FIN_OBJECT_CD VARCHAR2(4)
, ACTV_IND VARCHAR2(1)
, CONSTRAINT FS_TAX_REGION_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FS_TAX_REGION_T
ADD CONSTRAINT FS_TAX_REGION_TP1
PRIMARY KEY (TAX_REGION_CD)
/
-----------------------------------------------------------------------------
-- FS_TAX_REGION_TYPE_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FS_TAX_REGION_TYPE_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FS_TAX_REGION_TYPE_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FS_TAX_REGION_TYPE_T
(
TAX_REGION_TYP_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, TAX_REGION_TYP_NM VARCHAR2(100)
, CONSTRAINT FS_TAX_REGION_TYPE_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FS_TAX_REGION_TYPE_T
ADD CONSTRAINT FS_TAX_REGION_TYPE_TP1
PRIMARY KEY (TAX_REGION_TYP_CD)
/
-----------------------------------------------------------------------------
-- FS_TAX_STATE_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'FS_TAX_STATE_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE FS_TAX_STATE_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE FS_TAX_STATE_T
(
POSTAL_CNTRY_CD VARCHAR2(2)
, STATE_CD VARCHAR2(2)
, TAX_REGION_CD VARCHAR2(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ACTV_IND VARCHAR2(1)
, CONSTRAINT FS_TAX_STATE_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE FS_TAX_STATE_T
ADD CONSTRAINT FS_TAX_STATE_TP1
PRIMARY KEY (POSTAL_CNTRY_CD,STATE_CD,TAX_REGION_CD)
/
-----------------------------------------------------------------------------
-- GL_ACCT_BALANCES_HIST_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'GL_ACCT_BALANCES_HIST_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE GL_ACCT_BALANCES_HIST_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE GL_ACCT_BALANCES_HIST_T
(
UNIV_FISCAL_YR NUMBER(4)
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_OBJECT_CD VARCHAR2(4)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, CURR_BDLN_BAL_AMT NUMBER(19,2)
, ACLN_ACTLS_BAL_AMT NUMBER(19,2)
, ACLN_ENCUM_BAL_AMT NUMBER(19,2)
)
/
ALTER TABLE GL_ACCT_BALANCES_HIST_T
ADD CONSTRAINT GL_ACCT_BALANCES_HIST_TP1
PRIMARY KEY (UNIV_FISCAL_YR,FIN_COA_CD,ACCOUNT_NBR,SUB_ACCT_NBR,FIN_OBJECT_CD,FIN_SUB_OBJ_CD)
/
-----------------------------------------------------------------------------
-- GL_ACCT_BALANCES_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'GL_ACCT_BALANCES_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE GL_ACCT_BALANCES_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE GL_ACCT_BALANCES_T
(
UNIV_FISCAL_YR NUMBER(4)
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_OBJECT_CD VARCHAR2(4)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, CURR_BDLN_BAL_AMT NUMBER(19,2)
, ACLN_ACTLS_BAL_AMT NUMBER(19,2)
, ACLN_ENCUM_BAL_AMT NUMBER(19,2)
, TIMESTAMP DATE
)
/
ALTER TABLE GL_ACCT_BALANCES_T
ADD CONSTRAINT GL_ACCT_BALANCES_TP1
PRIMARY KEY (UNIV_FISCAL_YR,FIN_COA_CD,ACCOUNT_NBR,SUB_ACCT_NBR,FIN_OBJECT_CD,FIN_SUB_OBJ_CD)
/
-----------------------------------------------------------------------------
-- GL_BALANCE_HIST_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'GL_BALANCE_HIST_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE GL_BALANCE_HIST_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE GL_BALANCE_HIST_T
(
UNIV_FISCAL_YR NUMBER(4)
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_OBJECT_CD VARCHAR2(4)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, FIN_BALANCE_TYP_CD VARCHAR2(2)
, FIN_OBJ_TYP_CD VARCHAR2(2)
, ACLN_ANNL_BAL_AMT NUMBER(19,2)
, FIN_BEG_BAL_LN_AMT NUMBER(19,2)
, CONTR_GR_BB_AC_AMT NUMBER(19,2)
, MO1_ACCT_LN_AMT NUMBER(19,2)
, MO2_ACCT_LN_AMT NUMBER(19,2)
, MO3_ACCT_LN_AMT NUMBER(19,2)
, MO4_ACCT_LN_AMT NUMBER(19,2)
, MO5_ACCT_LN_AMT NUMBER(19,2)
, MO6_ACCT_LN_AMT NUMBER(19,2)
, MO7_ACCT_LN_AMT NUMBER(19,2)
, MO8_ACCT_LN_AMT NUMBER(19,2)
, MO9_ACCT_LN_AMT NUMBER(19,2)
, MO10_ACCT_LN_AMT NUMBER(19,2)
, MO11_ACCT_LN_AMT NUMBER(19,2)
, MO12_ACCT_LN_AMT NUMBER(19,2)
, MO13_ACCT_LN_AMT NUMBER(19,2)
)
/
ALTER TABLE GL_BALANCE_HIST_T
ADD CONSTRAINT GL_BALANCE_HIST_TP1
PRIMARY KEY (UNIV_FISCAL_YR,FIN_COA_CD,ACCOUNT_NBR,SUB_ACCT_NBR,FIN_OBJECT_CD,FIN_SUB_OBJ_CD,FIN_BALANCE_TYP_CD,FIN_OBJ_TYP_CD)
/
-----------------------------------------------------------------------------
-- GL_BALANCE_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'GL_BALANCE_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE GL_BALANCE_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE GL_BALANCE_T
(
UNIV_FISCAL_YR NUMBER(4)
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_OBJECT_CD VARCHAR2(4)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, FIN_BALANCE_TYP_CD VARCHAR2(2)
, FIN_OBJ_TYP_CD VARCHAR2(2)
, ACLN_ANNL_BAL_AMT NUMBER(19,2)
, FIN_BEG_BAL_LN_AMT NUMBER(19,2)
, CONTR_GR_BB_AC_AMT NUMBER(19,2)
, MO1_ACCT_LN_AMT NUMBER(19,2)
, MO2_ACCT_LN_AMT NUMBER(19,2)
, MO3_ACCT_LN_AMT NUMBER(19,2)
, MO4_ACCT_LN_AMT NUMBER(19,2)
, MO5_ACCT_LN_AMT NUMBER(19,2)
, MO6_ACCT_LN_AMT NUMBER(19,2)
, MO7_ACCT_LN_AMT NUMBER(19,2)
, MO8_ACCT_LN_AMT NUMBER(19,2)
, MO9_ACCT_LN_AMT NUMBER(19,2)
, MO10_ACCT_LN_AMT NUMBER(19,2)
, MO11_ACCT_LN_AMT NUMBER(19,2)
, MO12_ACCT_LN_AMT NUMBER(19,2)
, MO13_ACCT_LN_AMT NUMBER(19,2)
, TIMESTAMP DATE
)
/
ALTER TABLE GL_BALANCE_T
ADD CONSTRAINT GL_BALANCE_TP1
PRIMARY KEY (UNIV_FISCAL_YR,FIN_COA_CD,ACCOUNT_NBR,SUB_ACCT_NBR,FIN_OBJECT_CD,FIN_SUB_OBJ_CD,FIN_BALANCE_TYP_CD,FIN_OBJ_TYP_CD)
/
-----------------------------------------------------------------------------
-- GL_COR_CHG_GRP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'GL_COR_CHG_GRP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE GL_COR_CHG_GRP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE GL_COR_CHG_GRP_T
(
FDOC_NBR VARCHAR2(14)
, GL_COR_CHG_GRP_LN_NBR NUMBER(3)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, GL_COR_CRTA_NXT_LN_NBR NUMBER(3)
, GL_COR_CHG_NXT_LN_NBR NUMBER(3)
, CONSTRAINT GL_COR_CHG_GRP_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE GL_COR_CHG_GRP_T
ADD CONSTRAINT GL_COR_CHG_GRP_TP1
PRIMARY KEY (FDOC_NBR,GL_COR_CHG_GRP_LN_NBR)
/
-----------------------------------------------------------------------------
-- GL_COR_CHG_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'GL_COR_CHG_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE GL_COR_CHG_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE GL_COR_CHG_T
(
FDOC_NBR VARCHAR2(14)
, GL_COR_CHG_GRP_LN_NBR NUMBER(3)
, GL_COR_CHG_LN_NBR NUMBER(3)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, GL_COR_STRT_POS NUMBER(3)
, GL_COR_END_POS NUMBER(3)
, GL_COR_FIELD_VAL VARCHAR2(255)
, GL_COR_FIELD_NM VARCHAR2(50)
, CONSTRAINT GL_COR_CHG_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE GL_COR_CHG_T
ADD CONSTRAINT GL_COR_CHG_TP1
PRIMARY KEY (FDOC_NBR,GL_COR_CHG_GRP_LN_NBR,GL_COR_CHG_LN_NBR)
/
-----------------------------------------------------------------------------
-- GL_COR_CRTA_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'GL_COR_CRTA_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE GL_COR_CRTA_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE GL_COR_CRTA_T
(
FDOC_NBR VARCHAR2(14)
, GL_COR_CHG_GRP_LN_NBR NUMBER(3)
, GL_COR_CRTA_LN_NBR NUMBER(3)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, GL_COR_STRT_POS NUMBER(3)
, GL_COR_END_POS NUMBER(3)
, GL_COR_OPR_CD VARCHAR2(2)
, GL_COR_FIELD_VAL VARCHAR2(255)
, GL_COR_FIELD_NM VARCHAR2(50)
, CONSTRAINT GL_COR_CRTA_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE GL_COR_CRTA_T
ADD CONSTRAINT GL_COR_CRTA_TP1
PRIMARY KEY (FDOC_NBR,GL_COR_CHG_GRP_LN_NBR,GL_COR_CRTA_LN_NBR)
/
-----------------------------------------------------------------------------
-- GL_COR_DOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'GL_COR_DOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE GL_COR_DOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE GL_COR_DOC_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, GL_COR_TYP_CD VARCHAR2(1)
, GL_COR_SELECT_IND CHAR(1)
, GL_COR_FL_DEL_IND CHAR(1)
, GL_COR_ROW_CNT NUMBER(7)
, GL_COR_CHG_GRP_NXT_LN_NBR NUMBER(3)
, GL_COR_DEBIT_TOT_AMT NUMBER(19,2)
, GL_COR_CRDT_TOT_AMT NUMBER(19,2)
, GL_COR_INP_FL_NM VARCHAR2(255)
, GL_COR_OUT_FL_NM VARCHAR2(255)
, GL_COR_SCR_TXT CLOB
, GL_COR_BDGT_TOT_AMT NUMBER(19,2)
, CONSTRAINT GL_COR_DOC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE GL_COR_DOC_T
ADD CONSTRAINT GL_COR_DOC_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- GL_ENCUMBRANCE_HIST_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'GL_ENCUMBRANCE_HIST_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE GL_ENCUMBRANCE_HIST_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE GL_ENCUMBRANCE_HIST_T
(
UNIV_FISCAL_YR NUMBER(4)
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_OBJECT_CD VARCHAR2(4)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, FIN_BALANCE_TYP_CD VARCHAR2(2)
, FDOC_TYP_CD VARCHAR2(8)
, FS_ORIGIN_CD VARCHAR2(2)
, FDOC_NBR VARCHAR2(14)
, ACLN_ENCUM_AMT NUMBER(19,2)
, ACLN_ENCUM_CLS_AMT NUMBER(19,2)
)
/
ALTER TABLE GL_ENCUMBRANCE_HIST_T
ADD CONSTRAINT GL_ENCUMBRANCE_HIST_TP1
PRIMARY KEY (UNIV_FISCAL_YR,FIN_COA_CD,ACCOUNT_NBR,SUB_ACCT_NBR,FIN_OBJECT_CD,FIN_SUB_OBJ_CD,FIN_BALANCE_TYP_CD,FDOC_TYP_CD,FS_ORIGIN_CD,FDOC_NBR)
/
-----------------------------------------------------------------------------
-- GL_ENCUMBRANCE_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'GL_ENCUMBRANCE_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE GL_ENCUMBRANCE_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE GL_ENCUMBRANCE_T
(
UNIV_FISCAL_YR NUMBER(4)
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_OBJECT_CD VARCHAR2(4)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, FIN_BALANCE_TYP_CD VARCHAR2(2)
, FDOC_TYP_CD VARCHAR2(8)
, FS_ORIGIN_CD VARCHAR2(2)
, FDOC_NBR VARCHAR2(14)
, TRN_ENCUM_DESC VARCHAR2(40)
, TRN_ENCUM_DT DATE
, ACLN_ENCUM_AMT NUMBER(19,2)
, ACLN_ENCUM_CLS_AMT NUMBER(19,2)
, ACLN_ENCUM_PRG_CD VARCHAR2(1)
, TIMESTAMP DATE
)
/
ALTER TABLE GL_ENCUMBRANCE_T
ADD CONSTRAINT GL_ENCUMBRANCE_TP1
PRIMARY KEY (UNIV_FISCAL_YR,FIN_COA_CD,ACCOUNT_NBR,SUB_ACCT_NBR,FIN_OBJECT_CD,FIN_SUB_OBJ_CD,FIN_BALANCE_TYP_CD,FDOC_TYP_CD,FS_ORIGIN_CD,FDOC_NBR)
/
-----------------------------------------------------------------------------
-- GL_ENTRY_HIST_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'GL_ENTRY_HIST_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE GL_ENTRY_HIST_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE GL_ENTRY_HIST_T
(
UNIV_FISCAL_YR NUMBER(4) NOT NULL
, FIN_COA_CD VARCHAR2(2) NOT NULL
, FIN_OBJECT_CD VARCHAR2(4) NOT NULL
, FIN_BALANCE_TYP_CD VARCHAR2(2) NOT NULL
, UNIV_FISCAL_PRD_CD VARCHAR2(2) NOT NULL
, TRN_DEBIT_CRDT_CD VARCHAR2(1)
, VER_NBR NUMBER(8) default 1 NOT NULL
, TRN_LDGR_ENTR_AMT NUMBER(19,2)
, ROW_CNT NUMBER(7)
, CONSTRAINT GL_ENTRY_HIST_TP1 UNIQUE (UNIV_FISCAL_YR, FIN_COA_CD, FIN_OBJECT_CD, FIN_BALANCE_TYP_CD, UNIV_FISCAL_PRD_CD, TRN_DEBIT_CRDT_CD)
)
/
-----------------------------------------------------------------------------
-- GL_ENTRY_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'GL_ENTRY_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE GL_ENTRY_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE GL_ENTRY_T
(
UNIV_FISCAL_YR NUMBER(4)
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_OBJECT_CD VARCHAR2(4)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, FIN_BALANCE_TYP_CD VARCHAR2(2)
, FIN_OBJ_TYP_CD VARCHAR2(2)
, UNIV_FISCAL_PRD_CD VARCHAR2(2)
, FDOC_TYP_CD VARCHAR2(8)
, FS_ORIGIN_CD VARCHAR2(2)
, FDOC_NBR VARCHAR2(14)
, TRN_ENTR_SEQ_NBR NUMBER(5)
, TRN_LDGR_ENTR_DESC VARCHAR2(40)
, TRN_LDGR_ENTR_AMT NUMBER(19,2)
, TRN_DEBIT_CRDT_CD VARCHAR2(1)
, TRANSACTION_DT DATE
, ORG_DOC_NBR VARCHAR2(10)
, PROJECT_CD VARCHAR2(10)
, ORG_REFERENCE_ID VARCHAR2(8)
, FDOC_REF_TYP_CD VARCHAR2(8)
, FS_REF_ORIGIN_CD VARCHAR2(2)
, FDOC_REF_NBR VARCHAR2(14)
, FDOC_REVERSAL_DT DATE
, TRN_ENCUM_UPDT_CD VARCHAR2(1)
, TRN_POST_DT DATE
, TIMESTAMP DATE
)
/
ALTER TABLE GL_ENTRY_T
ADD CONSTRAINT GL_ENTRY_TP1
PRIMARY KEY (UNIV_FISCAL_YR,FIN_COA_CD,ACCOUNT_NBR,SUB_ACCT_NBR,FIN_OBJECT_CD,FIN_SUB_OBJ_CD,FIN_BALANCE_TYP_CD,FIN_OBJ_TYP_CD,UNIV_FISCAL_PRD_CD,FDOC_TYP_CD,FS_ORIGIN_CD,FDOC_NBR,TRN_ENTR_SEQ_NBR)
/
-----------------------------------------------------------------------------
-- GL_EXPEND_TRN_MT
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'GL_EXPEND_TRN_MT';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE GL_EXPEND_TRN_MT CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE GL_EXPEND_TRN_MT
(
UNIV_FISCAL_YR VARCHAR2(4)
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_OBJECT_CD VARCHAR2(4)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, FIN_BALANCE_TYP_CD VARCHAR2(2)
, FIN_OBJ_TYP_CD VARCHAR2(2)
, UNIV_FISCAL_PRD_CD VARCHAR2(2)
, PROJECT_CD VARCHAR2(10)
, ORG_REFERENCE_ID VARCHAR2(8)
, ACCT_OBJ_DCST_AMT NUMBER(19,2)
)
/
ALTER TABLE GL_EXPEND_TRN_MT
ADD CONSTRAINT GL_EXPEND_TRN_MTP1
PRIMARY KEY (UNIV_FISCAL_YR,FIN_COA_CD,ACCOUNT_NBR,SUB_ACCT_NBR,FIN_OBJECT_CD,FIN_SUB_OBJ_CD,FIN_BALANCE_TYP_CD,FIN_OBJ_TYP_CD,UNIV_FISCAL_PRD_CD,PROJECT_CD,ORG_REFERENCE_ID)
/
-----------------------------------------------------------------------------
-- GL_ID_BILL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'GL_ID_BILL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE GL_ID_BILL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE GL_ID_BILL_T
(
UNIV_FISCAL_PRD_CD VARCHAR2(2)
, UNIV_FISCAL_YR NUMBER(4)
, CREATE_DT DATE
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_OBJECT_CD VARCHAR2(4)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, FIN_BALANCE_TYP_CD VARCHAR2(2)
, FIN_OBJ_TYP_CD VARCHAR2(2)
, FDOC_IDBIL_SEQ_NBR VARCHAR2(2)
, FDOC_TYP_CD VARCHAR2(8)
, FS_ORIGIN_CD VARCHAR2(2)
, FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_IDBIL_ITM_AMT NUMBER(19,2) NOT NULL
, FDOC_IDBIL_NTE_TXT VARCHAR2(120) NOT NULL
, TRN_ENTR_SEQ_NBR NUMBER(5)
, CONSTRAINT GL_ID_BILL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE GL_ID_BILL_T
ADD CONSTRAINT GL_ID_BILL_TP1
PRIMARY KEY (UNIV_FISCAL_PRD_CD,UNIV_FISCAL_YR,CREATE_DT,FIN_COA_CD,ACCOUNT_NBR,SUB_ACCT_NBR,FIN_OBJECT_CD,FIN_SUB_OBJ_CD,FIN_BALANCE_TYP_CD,FIN_OBJ_TYP_CD,FDOC_IDBIL_SEQ_NBR,FDOC_TYP_CD,FS_ORIGIN_CD,FDOC_NBR,TRN_ENTR_SEQ_NBR)
/
CREATE INDEX GL_ID_BILL_TI2
ON GL_ID_BILL_T
(FDOC_TYP_CD)
/
CREATE INDEX GL_ID_BILL_TI3
ON GL_ID_BILL_T
(FS_ORIGIN_CD, FDOC_NBR)
/
CREATE INDEX GL_ID_BILL_TI4
ON GL_ID_BILL_T
(ACCOUNT_NBR, FDOC_TYP_CD, FIN_COA_CD)
/
-----------------------------------------------------------------------------
-- GL_OFFSET_DEFN_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'GL_OFFSET_DEFN_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE GL_OFFSET_DEFN_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE GL_OFFSET_DEFN_T
(
UNIV_FISCAL_YR NUMBER(4)
, FIN_COA_CD VARCHAR2(2)
, FDOC_TYP_CD VARCHAR2(8)
, FIN_BALANCE_TYP_CD VARCHAR2(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FIN_OBJECT_CD VARCHAR2(4)
, CONSTRAINT GL_OFFSET_DEFN_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE GL_OFFSET_DEFN_T
ADD CONSTRAINT GL_OFFSET_DEFN_TP1
PRIMARY KEY (UNIV_FISCAL_YR,FIN_COA_CD,FDOC_TYP_CD,FIN_BALANCE_TYP_CD)
/
-----------------------------------------------------------------------------
-- GL_ORG_RVRSN_CTGRY_AMT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'GL_ORG_RVRSN_CTGRY_AMT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE GL_ORG_RVRSN_CTGRY_AMT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE GL_ORG_RVRSN_CTGRY_AMT_T
(
FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, SUB_ACCT_NBR VARCHAR2(5)
, ORG_RVRSN_CTGRY_CD VARCHAR2(8)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ORG_TOT_ACTL_AMT NUMBER(19,2)
, ORG_TOT_BDGT_AMT NUMBER(19,2)
, ORG_TOT_ENCUM_AMT NUMBER(19,2)
, ORG_TOT_CF_AMT NUMBER(19,2)
, ORG_TOT_AVAIL_AMT NUMBER(19,2)
, CONSTRAINT GL_ORG_RVRSN_CTGRY_AMT_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE GL_ORG_RVRSN_CTGRY_AMT_T
ADD CONSTRAINT GL_ORG_RVRSN_CTGRY_AMT_TP1
PRIMARY KEY (FIN_COA_CD,ACCOUNT_NBR,SUB_ACCT_NBR,ORG_RVRSN_CTGRY_CD)
/
-----------------------------------------------------------------------------
-- GL_ORG_RVRSN_UNIT_WRK_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'GL_ORG_RVRSN_UNIT_WRK_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE GL_ORG_RVRSN_UNIT_WRK_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE GL_ORG_RVRSN_UNIT_WRK_T
(
FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, SUB_ACCT_NBR VARCHAR2(5)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ORG_TOT_RVRSN_AMT NUMBER(19,2)
, ORG_TOT_CF_AMT NUMBER(19,2)
, ORG_TOT_AVAIL_AMT NUMBER(19,2)
, ORG_TOT_CSH_AMT NUMBER(19,2)
, CONSTRAINT GL_ORG_RVRSN_UNIT_WRK_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE GL_ORG_RVRSN_UNIT_WRK_T
ADD CONSTRAINT GL_ORG_RVRSN_UNIT_WRK_TP1
PRIMARY KEY (FIN_COA_CD,ACCOUNT_NBR,SUB_ACCT_NBR)
/
-----------------------------------------------------------------------------
-- GL_PENDING_BALANCES_MT
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'GL_PENDING_BALANCES_MT';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE GL_PENDING_BALANCES_MT CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE GL_PENDING_BALANCES_MT
(
PERSON_UNVL_ID VARCHAR2(40)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, APPR_BUDGET NUMBER(19,2)
, APPR_ACTUAL NUMBER(19,2)
, APPR_ENCUM NUMBER(19,2)
, PEND_BUDGET NUMBER(19,2)
, PEND_ACTUAL NUMBER(19,2)
, PEND_ENCUM NUMBER(19,2)
, CONSTRAINT GL_PENDING_BALANCES_MTC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE GL_PENDING_BALANCES_MT
ADD CONSTRAINT GL_PENDING_BALANCES_MTP1
PRIMARY KEY (PERSON_UNVL_ID)
/
-----------------------------------------------------------------------------
-- GL_PENDING_ENTRY_MT
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'GL_PENDING_ENTRY_MT';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE GL_PENDING_ENTRY_MT CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE GL_PENDING_ENTRY_MT
(
SESID VARCHAR2(36)
, FS_ORIGIN_CD VARCHAR2(2)
, FDOC_NBR VARCHAR2(14)
, TRN_ENTR_SEQ_NBR NUMBER(5)
, VER_NBR NUMBER(8) default 1 NOT NULL
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_OBJECT_CD VARCHAR2(4)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, FIN_BALANCE_TYP_CD VARCHAR2(2)
, FIN_OBJ_TYP_CD VARCHAR2(2)
, UNIV_FISCAL_YR NUMBER(4)
, UNIV_FISCAL_PRD_CD VARCHAR2(2)
, TRN_LDGR_ENTR_DESC VARCHAR2(40)
, TRN_LDGR_ENTR_AMT NUMBER(19,2)
, TRN_DEBIT_CRDT_CD VARCHAR2(1)
, TRANSACTION_DT DATE
, FDOC_TYP_CD VARCHAR2(8)
, ORG_DOC_NBR VARCHAR2(10)
, PROJECT_CD VARCHAR2(10)
, ORG_REFERENCE_ID VARCHAR2(8)
, FDOC_REF_TYP_CD VARCHAR2(8)
, FS_REF_ORIGIN_CD VARCHAR2(2)
, FDOC_REF_NBR VARCHAR2(14)
, FDOC_REVERSAL_DT DATE
, TRN_ENCUM_UPDT_CD VARCHAR2(1)
, FDOC_APPROVED_CD VARCHAR2(1)
, ACCT_SF_FINOBJ_CD VARCHAR2(4)
, TRN_ENTR_OFST_CD VARCHAR2(1)
, TRNENTR_PROCESS_TM DATE
)
/
ALTER TABLE GL_PENDING_ENTRY_MT
ADD CONSTRAINT GL_PENDING_ENTRY_MTP1
PRIMARY KEY (SESID,FS_ORIGIN_CD,FDOC_NBR,TRN_ENTR_SEQ_NBR)
/
-----------------------------------------------------------------------------
-- GL_PENDING_ENTRY_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'GL_PENDING_ENTRY_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE GL_PENDING_ENTRY_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE GL_PENDING_ENTRY_T
(
FS_ORIGIN_CD VARCHAR2(2)
, FDOC_NBR VARCHAR2(14)
, TRN_ENTR_SEQ_NBR NUMBER(5)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_OBJECT_CD VARCHAR2(4)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, FIN_BALANCE_TYP_CD VARCHAR2(2)
, FIN_OBJ_TYP_CD VARCHAR2(2)
, UNIV_FISCAL_YR NUMBER(4)
, UNIV_FISCAL_PRD_CD VARCHAR2(2)
, TRN_LDGR_ENTR_DESC VARCHAR2(40)
, TRN_LDGR_ENTR_AMT NUMBER(19,2)
, TRN_DEBIT_CRDT_CD VARCHAR2(1)
, TRANSACTION_DT DATE
, FDOC_TYP_CD VARCHAR2(8)
, ORG_DOC_NBR VARCHAR2(10)
, PROJECT_CD VARCHAR2(10)
, ORG_REFERENCE_ID VARCHAR2(8)
, FDOC_REF_TYP_CD VARCHAR2(8)
, FS_REF_ORIGIN_CD VARCHAR2(2)
, FDOC_REF_NBR VARCHAR2(14)
, FDOC_REVERSAL_DT DATE
, TRN_ENCUM_UPDT_CD VARCHAR2(1)
, FDOC_APPROVED_CD VARCHAR2(1)
, ACCT_SF_FINOBJ_CD VARCHAR2(4)
, TRN_ENTR_OFST_CD VARCHAR2(1)
, TRNENTR_PROCESS_TM DATE
, CONSTRAINT GL_PENDING_ENTRY_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE GL_PENDING_ENTRY_T
ADD CONSTRAINT GL_PENDING_ENTRY_TP1
PRIMARY KEY (FS_ORIGIN_CD,FDOC_NBR,TRN_ENTR_SEQ_NBR)
/
CREATE INDEX GL_PENDING_ENTRY_TI2
ON GL_PENDING_ENTRY_T
(UNIV_FISCAL_YR, FIN_COA_CD, ACCOUNT_NBR, SUB_ACCT_NBR, FIN_OBJECT_CD, FIN_SUB_OBJ_CD, FIN_BALANCE_TYP_CD, FIN_OBJ_TYP_CD)
/
CREATE INDEX GL_PENDING_ENTRY_TI3
ON GL_PENDING_ENTRY_T
(UNIV_FISCAL_YR, FIN_COA_CD, ACCOUNT_NBR, FIN_OBJECT_CD, FIN_BALANCE_TYP_CD, ACCT_SF_FINOBJ_CD)
/
CREATE INDEX GL_PENDING_ENTRY_TI4
ON GL_PENDING_ENTRY_T
(FIN_OBJ_TYP_CD)
/
CREATE INDEX GL_PENDING_ENTRY_TI5
ON GL_PENDING_ENTRY_T
(FS_ORIGIN_CD, FDOC_NBR)
/
CREATE INDEX GL_PENDING_ENTRY_TI6
ON GL_PENDING_ENTRY_T
(UNIV_FISCAL_YR, FIN_COA_CD, ACCOUNT_NBR, FIN_OBJECT_CD)
/
CREATE INDEX GL_PENDING_ENTRY_TI7
ON GL_PENDING_ENTRY_T
(FDOC_NBR)
/
-----------------------------------------------------------------------------
-- GL_REVERSAL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'GL_REVERSAL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE GL_REVERSAL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE GL_REVERSAL_T
(
FDOC_REVERSAL_DT DATE
, UNIV_FISCAL_YR NUMBER(4)
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_OBJECT_CD VARCHAR2(4)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, FIN_BALANCE_TYP_CD VARCHAR2(2)
, FIN_OBJ_TYP_CD VARCHAR2(2)
, UNIV_FISCAL_PRD_CD VARCHAR2(2)
, FDOC_TYP_CD VARCHAR2(8)
, FS_ORIGIN_CD VARCHAR2(2)
, FDOC_NBR VARCHAR2(14)
, TRN_ENTR_SEQ_NBR NUMBER(5)
, TRN_LDGR_ENTR_DESC VARCHAR2(40)
, TRN_LDGR_ENTR_AMT NUMBER(19,2)
, TRN_DEBIT_CRDT_CD VARCHAR2(1)
, TRANSACTION_DT DATE
, ORG_DOC_NBR VARCHAR2(10)
, PROJECT_CD VARCHAR2(10)
, ORG_REFERENCE_ID VARCHAR2(8)
, FDOC_REF_TYP_CD VARCHAR2(8)
, FS_REF_ORIGIN_CD VARCHAR2(2)
, FDOC_REF_NBR VARCHAR2(14)
, TRN_ENCUM_UPDT_CD VARCHAR2(1)
, TRN_POST_DT DATE
)
/
ALTER TABLE GL_REVERSAL_T
ADD CONSTRAINT GL_REVERSAL_TP1
PRIMARY KEY (FDOC_REVERSAL_DT,UNIV_FISCAL_YR,FIN_COA_CD,ACCOUNT_NBR,SUB_ACCT_NBR,FIN_OBJECT_CD,FIN_SUB_OBJ_CD,FIN_BALANCE_TYP_CD,FIN_OBJ_TYP_CD,UNIV_FISCAL_PRD_CD,FDOC_TYP_CD,FS_ORIGIN_CD,FDOC_NBR,TRN_ENTR_SEQ_NBR)
/
-----------------------------------------------------------------------------
-- GL_SF_BALANCES_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'GL_SF_BALANCES_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE GL_SF_BALANCES_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE GL_SF_BALANCES_T
(
UNIV_FISCAL_YR NUMBER(4)
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, FIN_OBJECT_CD VARCHAR2(4)
, ACCT_SF_CD VARCHAR2(1)
, CURR_BDGT_BAL_AMT NUMBER(19,2)
, ACCT_ACTL_XPND_AMT NUMBER(19,2)
, ACCT_ENCUM_AMT NUMBER(19,2)
, TIMESTAMP DATE
)
/
ALTER TABLE GL_SF_BALANCES_T
ADD CONSTRAINT GL_SF_BALANCES_TP1
PRIMARY KEY (UNIV_FISCAL_YR,FIN_COA_CD,ACCOUNT_NBR,FIN_OBJECT_CD)
/
CREATE INDEX GL_SF_BALANCES_TI2
ON GL_SF_BALANCES_T
(UNIV_FISCAL_YR, FIN_COA_CD, FIN_OBJECT_CD)
/
CREATE INDEX GL_SF_BALANCES_TI3
ON GL_SF_BALANCES_T
(TIMESTAMP)
/
-----------------------------------------------------------------------------
-- GL_SF_REBUILD_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'GL_SF_REBUILD_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE GL_SF_REBUILD_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE GL_SF_REBUILD_T
(
FIN_COA_CD VARCHAR2(2)
, ACCT_FOBJ_TYP_CD VARCHAR2(1)
, ACCT_NBR_FOBJ_CD VARCHAR2(7)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CONSTRAINT GL_SF_REBUILD_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE GL_SF_REBUILD_T
ADD CONSTRAINT GL_SF_REBUILD_TP1
PRIMARY KEY (FIN_COA_CD,ACCT_FOBJ_TYP_CD,ACCT_NBR_FOBJ_CD)
/
-----------------------------------------------------------------------------
-- OLE_ACC_SUFF_FUND_CHK_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_ACC_SUFF_FUND_CHK_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_ACC_SUFF_FUND_CHK_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_ACC_SUFF_FUND_CHK_T
(
ACCOUNT_NBR VARCHAR2(40)
, FIN_COA_CD VARCHAR2(40)
, OLE_SFC_CHK_ID NUMBER(8)
, OLE_SFC_ENCUM_METHOD VARCHAR2(10)
, OLE_SFC_ENCUM_AMT NUMBER(10,2)
, OLE_SFC_EXP_AMT NUMBER(10,2)
, OLE_SFC_ENCUM_CON_TYP VARCHAR2(10)
, OLE_NOTIFICATION_OPT VARCHAR2(50)
, VER_NBR NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
)
/
ALTER TABLE OLE_ACC_SUFF_FUND_CHK_T
ADD CONSTRAINT OLE_ACC_SUFF_FUND_CHK_TP1
PRIMARY KEY (ACCOUNT_NBR,FIN_COA_CD)
/
-----------------------------------------------------------------------------
-- OLE_CAT_LOC_STATUS_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_CAT_LOC_STATUS_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_CAT_LOC_STATUS_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_CAT_LOC_STATUS_T
(
LOC_STATUS_ID VARCHAR2(40)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) NOT NULL
, LOC_STATUS_CD VARCHAR2(40) NOT NULL
, LOC_STATUS_NM VARCHAR2(100) NOT NULL
, SRC VARCHAR2(100) NOT NULL
, SRC_DT DATE NOT NULL
, ROW_ACT_IND VARCHAR2(1) NOT NULL
, CONSTRAINT LOC_STATUS_CD_UQ UNIQUE (LOC_STATUS_CD)
)
/
ALTER TABLE OLE_CAT_LOC_STATUS_T
ADD CONSTRAINT OLE_CAT_LOC_STATUS_TP1
PRIMARY KEY (LOC_STATUS_ID)
/
-----------------------------------------------------------------------------
-- OLE_CA_ACCT_ENCUM_CNSTRT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_CA_ACCT_ENCUM_CNSTRT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_CA_ACCT_ENCUM_CNSTRT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_CA_ACCT_ENCUM_CNSTRT_T
(
FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, OLE_ENCUM_CNSTRT_AMT NUMBER(19,4) NOT NULL
, OLE_ENCUM_CNSTRT_AMT_TYP VARCHAR2(1) NOT NULL
, OLE_CNSTRT_TYP_ID NUMBER(8) NOT NULL
, OLE_SFC_TYP_ID NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) NOT NULL
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
)
/
ALTER TABLE OLE_CA_ACCT_ENCUM_CNSTRT_T
ADD CONSTRAINT OLE_CA_ACCT_ENCUM_CNSTRT_TP1
PRIMARY KEY (FIN_COA_CD,ACCOUNT_NBR)
/
-----------------------------------------------------------------------------
-- OLE_CA_ACCT_EXP_CNSTRT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_CA_ACCT_EXP_CNSTRT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_CA_ACCT_EXP_CNSTRT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_CA_ACCT_EXP_CNSTRT_T
(
FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, OLE_EXP_CNSTRT_AMT NUMBER(19,4) NOT NULL
, OLE_EXP_CNSTRT_AMT_TYP VARCHAR2(1) NOT NULL
, OLE_CNSTRT_TYP_ID NUMBER(8) NOT NULL
, OLE_SFC_TYP_ID NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) NOT NULL
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
)
/
ALTER TABLE OLE_CA_ACCT_EXP_CNSTRT_T
ADD CONSTRAINT OLE_CA_ACCT_EXP_CNSTRT_TP1
PRIMARY KEY (FIN_COA_CD,ACCOUNT_NBR)
/
-----------------------------------------------------------------------------
-- OLE_CA_ACCT_LGCY_LMS_FND_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_CA_ACCT_LGCY_LMS_FND_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_CA_ACCT_LGCY_LMS_FND_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_CA_ACCT_LGCY_LMS_FND_T
(
OLE_CA_ACCT_LGCY_LMS_FND_ID NUMBER(8)
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, OLE_LGCY_LIB_FUND_CD VARCHAR2(100) NOT NULL
, OLE_LGCY_LIB_FUND_NTE VARCHAR2(700)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) NOT NULL
)
/
ALTER TABLE OLE_CA_ACCT_LGCY_LMS_FND_T
ADD CONSTRAINT OLE_CA_ACCT_LGCY_LMS_FND_TP1
PRIMARY KEY (OLE_CA_ACCT_LGCY_LMS_FND_ID,FIN_COA_CD,ACCOUNT_NBR)
/
-----------------------------------------------------------------------------
-- OLE_CA_ACCT_SFC_TYPE_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_CA_ACCT_SFC_TYPE_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_CA_ACCT_SFC_TYPE_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_CA_ACCT_SFC_TYPE_T
(
OLE_SFC_TYP_ID NUMBER(8)
, OLE_SFC_TYP VARCHAR2(40) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) NOT NULL
, ROW_ACT_IND VARCHAR2(1) NOT NULL
)
/
ALTER TABLE OLE_CA_ACCT_SFC_TYPE_T
ADD CONSTRAINT OLE_CA_ACCT_SFC_TYPE_TP1
PRIMARY KEY (OLE_SFC_TYP_ID)
/
-----------------------------------------------------------------------------
-- OLE_CA_ACCT_STWD_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_CA_ACCT_STWD_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_CA_ACCT_STWD_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_CA_ACCT_STWD_T
(
OLE_CA_ACCT_STWD_ID NUMBER(8)
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, OLE_STWD_TYP_ID NUMBER(8) NOT NULL
, OLE_STWD_NTE VARCHAR2(700)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) NOT NULL
)
/
ALTER TABLE OLE_CA_ACCT_STWD_T
ADD CONSTRAINT OLE_CA_ACCT_STWD_TP1
PRIMARY KEY (OLE_CA_ACCT_STWD_ID,FIN_COA_CD,ACCOUNT_NBR)
/
-----------------------------------------------------------------------------
-- OLE_CA_ACCT_STWD_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_CA_ACCT_STWD_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_CA_ACCT_STWD_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_CA_ACCT_STWD_TYP_T
(
OLE_STWD_TYP_ID NUMBER(8)
, OLE_STWD_TYP VARCHAR2(40) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) NOT NULL
, ROW_ACT_IND VARCHAR2(1)
)
/
ALTER TABLE OLE_CA_ACCT_STWD_TYP_T
ADD CONSTRAINT OLE_CA_ACCT_STWD_TYP_TP1
PRIMARY KEY (OLE_STWD_TYP_ID)
/
-----------------------------------------------------------------------------
-- OLE_CNSTRT_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_CNSTRT_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_CNSTRT_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_CNSTRT_TYP_T
(
OLE_CNSTRT_TYP_ID NUMBER(8)
, OLE_CNSTRT_TYP VARCHAR2(40) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) NOT NULL
, ROW_ACT_IND VARCHAR2(1)
)
/
ALTER TABLE OLE_CNSTRT_TYP_T
ADD CONSTRAINT OLE_CNSTRT_TYP_TP1
PRIMARY KEY (OLE_CNSTRT_TYP_ID)
/
-----------------------------------------------------------------------------
-- OLE_CURR_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_CURR_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_CURR_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_CURR_TYP_T
(
OLE_CURR_TYP_ID NUMBER(8)
, OLE_CURR_TYP VARCHAR2(200) NOT NULL
, OLE_CURR_CNTRY VARCHAR2(100) NOT NULL
, OLE_CURR_ALPHA_CD VARCHAR2(3) NOT NULL
, OLE_CURR_NUM_CD NUMBER(4) NOT NULL
, OLE_CURR_MIN_UN VARCHAR2(5) NOT NULL
, VER_NBR NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
, ROW_ACT_IND VARCHAR2(1) NOT NULL
)
/
ALTER TABLE OLE_CURR_TYP_T
ADD CONSTRAINT OLE_CURR_TYP_TP1
PRIMARY KEY (OLE_CURR_TYP_ID)
/
-----------------------------------------------------------------------------
-- OLE_DEFAULTABLE_COLUMNS_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_DEFAULTABLE_COLUMNS_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_DEFAULTABLE_COLUMNS_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_DEFAULTABLE_COLUMNS_T
(
OLE_DEFAULTABLE_COLUMN_ID NUMBER(8)
, DOC_TYPE_ID VARCHAR2(40)
, DOC_COLUMN VARCHAR2(45)
, VER_NBR NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
, ROW_ACT_IND VARCHAR2(1) NOT NULL
)
/
ALTER TABLE OLE_DEFAULTABLE_COLUMNS_T
ADD CONSTRAINT OLE_DEFAULTABLE_COLUMNS_TP1
PRIMARY KEY (OLE_DEFAULTABLE_COLUMN_ID)
/
-----------------------------------------------------------------------------
-- OLE_DEFAULT_VALUE_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_DEFAULT_VALUE_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_DEFAULT_VALUE_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_DEFAULT_VALUE_T
(
OLE_DEFAULT_VALUE_ID NUMBER(8) default 0
, OLE_DEFAULTABLE_COLUMN_ID NUMBER(8) NOT NULL
, DEFAULT_VALUE VARCHAR2(50)
, DEFAULT_VALUE_FOR VARCHAR2(45)
, USER_ID VARCHAR2(45)
, ROLE_ID VARCHAR2(40)
, VER_NBR NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
, ROW_ACT_IND VARCHAR2(1) NOT NULL
)
/
ALTER TABLE OLE_DEFAULT_VALUE_T
ADD CONSTRAINT OLE_DEFAULT_VALUE_TP1
PRIMARY KEY (OLE_DEFAULT_VALUE_ID)
/
-----------------------------------------------------------------------------
-- OLE_DOCSTORE_LINKS_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_DOCSTORE_LINKS_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_DOCSTORE_LINKS_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_DOCSTORE_LINKS_T
(
DOCSTORE_LINKS_ID NUMBER(8)
, OLE_DOCUMENT1_UUID VARCHAR2(50) NOT NULL
, OLE_DOCUMENT2_UUID VARCHAR2(50) NOT NULL
, DOC_TYP_1 VARCHAR2(50) NOT NULL
, DOC_TYP_2 VARCHAR2(50) NOT NULL
, VER_NBR NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
)
/
ALTER TABLE OLE_DOCSTORE_LINKS_T
ADD CONSTRAINT OLE_DOCSTORE_LINKS_TP1
PRIMARY KEY (DOCSTORE_LINKS_ID)
/
-----------------------------------------------------------------------------
-- OLE_DV_FP_ACCT_LINES_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_DV_FP_ACCT_LINES_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_DV_FP_ACCT_LINES_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_DV_FP_ACCT_LINES_T
(
FDOC_NBR VARCHAR2(14)
, FDOC_LINE_NBR NUMBER(7)
, FDOC_LN_TYP_CD VARCHAR2(1)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) NOT NULL
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, FDOC_POST_YR NUMBER(4)
, FIN_OBJECT_CD VARCHAR2(4)
, FIN_BALANCE_TYP_CD VARCHAR2(2)
, FDOC_LINE_AMT NUMBER(19,2)
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, PROJECT_CD VARCHAR2(10)
, ORG_REFERENCE_ID VARCHAR2(8)
, FS_REF_ORIGIN_CD VARCHAR2(2)
, FDOC_REF_NBR VARCHAR2(14)
, FDOC_REF_TYP_CD VARCHAR2(8)
, FDOC_OVERRIDE_CD VARCHAR2(100)
, FDOC_LINE_DESC VARCHAR2(40)
, FDOC_LINE_DBCR_CD VARCHAR2(1)
, TRN_ENCUM_UPDT_CD VARCHAR2(1)
, ACLN_PCT NUMBER(35,20)
, CONSTRAINT OLE_DV_FP_ACCT_LINES_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE OLE_DV_FP_ACCT_LINES_T
ADD CONSTRAINT OLE_DV_FP_ACCT_LINES_TP1
PRIMARY KEY (FDOC_NBR,FDOC_LINE_NBR,FDOC_LN_TYP_CD)
/
-----------------------------------------------------------------------------
-- OLE_DV_FP_PAYEE_DTL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_DV_FP_PAYEE_DTL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_DV_FP_PAYEE_DTL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_DV_FP_PAYEE_DTL_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) NOT NULL
, DV_PMT_REAS_CD VARCHAR2(1)
, DV_ALIEN_PMT_IND CHAR(1)
, DV_DEPOSIT_ACC CHAR(1)
, DV_PAYEE_ID_NBR VARCHAR2(21)
, DV_PAYEE_PRSN_NM VARCHAR2(123)
, DV_PAYEE_LN1_ADDR VARCHAR2(45)
, DV_PAYEE_LN2_ADDR VARCHAR2(45)
, DV_PAYEE_CTY_NM VARCHAR2(37)
, DV_PAYEE_ST_CD VARCHAR2(2)
, DV_PAYEE_ZIP_CD VARCHAR2(20)
, DV_RMT_PRSN_NM VARCHAR2(123)
, DV_RMT_LN1_ADDR VARCHAR2(45)
, DV_RMT_LN2_ADDR VARCHAR2(45)
, DV_RMT_CTY_NM VARCHAR2(37)
, DV_RMT_ST_CD VARCHAR2(2)
, DV_RMT_ZIP_CD VARCHAR2(20)
, DV_PAYEE_EMP_IND CHAR(1)
, DV_PAYEE_CNTRY_CD VARCHAR2(2)
, DV_RMT_CNTRY_CD VARCHAR2(2)
, DV_PAYEE_TYP_CD VARCHAR2(1)
, CONSTRAINT OLE_DV_FP_PAYEE_DTL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE OLE_DV_FP_PAYEE_DTL_T
ADD CONSTRAINT OLE_DV_FP_PAYEE_DTL_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- OLE_EXCHANGE_RT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_EXCHANGE_RT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_EXCHANGE_RT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_EXCHANGE_RT_T
(
OLE_EXCHANGE_RT_ID NUMBER(8)
, OLE_CURR_TYP_ID NUMBER(8) NOT NULL
, OLE_EXCHANGE_RT NUMBER(19,6)
, OLE_EXCHANGE_RT_SRC VARCHAR2(700)
, OLE_EXCHANGE_RT_DT DATE
, VER_NBR NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
, ROW_ACT_IND VARCHAR2(1) NOT NULL
)
/
ALTER TABLE OLE_EXCHANGE_RT_T
ADD CONSTRAINT OLE_EXCHANGE_RT_TP1
PRIMARY KEY (OLE_EXCHANGE_RT_ID)
/
-----------------------------------------------------------------------------
-- OLE_INV_SUB_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_INV_SUB_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_INV_SUB_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_INV_SUB_TYP_T
(
OLE_INV_SUB_TYP_ID NUMBER(10)
, INV_SUB_TYP VARCHAR2(100) NOT NULL
, INV_SUB_TYP_DESC VARCHAR2(200)
, VER_NBR NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
, ROW_ACT_IND VARCHAR2(1) NOT NULL
)
/
ALTER TABLE OLE_INV_SUB_TYP_T
ADD CONSTRAINT OLE_INV_SUB_TYP_TP1
PRIMARY KEY (OLE_INV_SUB_TYP_ID)
/
-----------------------------------------------------------------------------
-- OLE_INV_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_INV_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_INV_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_INV_TYP_T
(
OLE_INV_TYP_ID NUMBER(10)
, INV_TYP VARCHAR2(100) NOT NULL
, INV_TYP_DESC VARCHAR2(200)
, VER_NBR NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
, ROW_ACT_IND VARCHAR2(1) NOT NULL
)
/
ALTER TABLE OLE_INV_TYP_T
ADD CONSTRAINT OLE_INV_TYP_TP1
PRIMARY KEY (OLE_INV_TYP_ID)
/
-----------------------------------------------------------------------------
-- OLE_ITM_PRC_SRC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_ITM_PRC_SRC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_ITM_PRC_SRC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_ITM_PRC_SRC_T
(
ITM_PRC_SRC_ID NUMBER(8)
, OLE_ITM_PRC_SRC VARCHAR2(100) NOT NULL
, VER_NBR NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
, ROW_ACT_IND VARCHAR2(1) NOT NULL
)
/
ALTER TABLE OLE_ITM_PRC_SRC_T
ADD CONSTRAINT OLE_ITM_PRC_SRC_TP1
PRIMARY KEY (ITM_PRC_SRC_ID)
/
-----------------------------------------------------------------------------
-- OLE_LIC_RQMT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_LIC_RQMT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_LIC_RQMT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_LIC_RQMT_T
(
LIC_RQMT_CD VARCHAR2(20)
, LIC_RQMT_DESC VARCHAR2(200)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) NOT NULL
, ACT_IND VARCHAR2(1) default 'Y'
)
/
ALTER TABLE OLE_LIC_RQMT_T
ADD CONSTRAINT OLE_LIC_RQMT_TP1
PRIMARY KEY (LIC_RQMT_CD)
/
-----------------------------------------------------------------------------
-- OLE_NTE_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_NTE_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_NTE_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_NTE_TYP_T
(
OLE_NTE_TYP_ID NUMBER(10)
, OLE_NTE_TYPE VARCHAR2(100) NOT NULL
, VER_NBR NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
, ROW_ACT_IND VARCHAR2(1) NOT NULL
)
/
ALTER TABLE OLE_NTE_TYP_T
ADD CONSTRAINT OLE_NTE_TYP_TP1
PRIMARY KEY (OLE_NTE_TYP_ID)
/
-----------------------------------------------------------------------------
-- OLE_PMT_MTHD_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_PMT_MTHD_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_PMT_MTHD_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_PMT_MTHD_T
(
OLE_PMT_MTHD_ID NUMBER(10)
, PMT_MTHD VARCHAR2(100) NOT NULL
, PMT_MTHD_DESC VARCHAR2(200)
, VER_NBR NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
, ROW_ACT_IND VARCHAR2(1) NOT NULL
)
/
ALTER TABLE OLE_PMT_MTHD_T
ADD CONSTRAINT OLE_PMT_MTHD_TP1
PRIMARY KEY (OLE_PMT_MTHD_ID)
/
-----------------------------------------------------------------------------
-- OLE_PMT_RQST_ITM_NTE_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_PMT_RQST_ITM_NTE_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_PMT_RQST_ITM_NTE_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_PMT_RQST_ITM_NTE_T
(
OLE_PMT_RQST_ITM_NTE_ID NUMBER(10)
, PMT_RQST_ITM_ID NUMBER(10)
, OLE_NTE VARCHAR2(2000) NOT NULL
, VER_NBR NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
)
/
ALTER TABLE OLE_PMT_RQST_ITM_NTE_T
ADD CONSTRAINT OLE_PMT_RQST_ITM_NTE_TP1
PRIMARY KEY (OLE_PMT_RQST_ITM_NTE_ID,PMT_RQST_ITM_ID)
/
-----------------------------------------------------------------------------
-- OLE_PUR_CAT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_PUR_CAT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_PUR_CAT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_PUR_CAT_T
(
OLE_CAT_ID NUMBER(8)
, OLE_CATEGORY VARCHAR2(45)
, VER_NBR NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
, ROW_ACTV_IND VARCHAR2(1)
)
/
ALTER TABLE OLE_PUR_CAT_T
ADD CONSTRAINT OLE_PUR_CAT_TP1
PRIMARY KEY (OLE_CAT_ID)
/
-----------------------------------------------------------------------------
-- OLE_PUR_FRMT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_PUR_FRMT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_PUR_FRMT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_PUR_FRMT_T
(
OLE_FRMT_ID NUMBER(8)
, OLE_FORMAT VARCHAR2(45)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) NOT NULL
, ROW_ACTV_IND VARCHAR2(1)
)
/
ALTER TABLE OLE_PUR_FRMT_T
ADD CONSTRAINT OLE_PUR_FRMT_TP1
PRIMARY KEY (OLE_FRMT_ID)
/
-----------------------------------------------------------------------------
-- OLE_PUR_PO_ERR_CDS_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_PUR_PO_ERR_CDS_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_PUR_PO_ERR_CDS_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_PUR_PO_ERR_CDS_T
(
ERR_ID NUMBER(10)
, ERROR VARCHAR2(200) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) NOT NULL
, ROW_ACT_IND VARCHAR2(1) NOT NULL
)
/
ALTER TABLE OLE_PUR_PO_ERR_CDS_T
ADD CONSTRAINT OLE_PUR_PO_ERR_CDS_TP1
PRIMARY KEY (ERR_ID)
/
-----------------------------------------------------------------------------
-- OLE_PUR_PO_FAIL_DOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_PUR_PO_FAIL_DOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_PUR_PO_FAIL_DOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_PUR_PO_FAIL_DOC_T
(
PO_FAIL_DOC_ID NUMBER(10)
, PO_LOAD_SUM_ID NUMBER(10)
, OLE_VNDR_PO_ID VARCHAR2(100)
, OLE_VNDR_IT_ID VARCHAR2(100)
, ERR_ID NUMBER(10) NOT NULL
, VER_NBR NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
, ISBN VARCHAR2(50)
, TITLE VARCHAR2(700)
)
/
ALTER TABLE OLE_PUR_PO_FAIL_DOC_T
ADD CONSTRAINT OLE_PUR_PO_FAIL_DOC_TP1
PRIMARY KEY (PO_FAIL_DOC_ID,PO_LOAD_SUM_ID)
/
-----------------------------------------------------------------------------
-- OLE_PUR_PO_ITM_NTE_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_PUR_PO_ITM_NTE_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_PUR_PO_ITM_NTE_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_PUR_PO_ITM_NTE_T
(
OLE_PO_ITM_NTE_ID NUMBER(10)
, FDOC_NBR VARCHAR2(14)
, PO_ITM_ID NUMBER(10)
, OLE_NTE VARCHAR2(2000) NOT NULL
, OLE_NTE_TYP_ID NUMBER(10)
, VER_NBR NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
)
/
ALTER TABLE OLE_PUR_PO_ITM_NTE_T
ADD CONSTRAINT OLE_PUR_PO_ITM_NTE_TP1
PRIMARY KEY (OLE_PO_ITM_NTE_ID,FDOC_NBR,PO_ITM_ID)
/
-----------------------------------------------------------------------------
-- OLE_PUR_PO_ITM_ORDR_STAT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_PUR_PO_ITM_ORDR_STAT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_PUR_PO_ITM_ORDR_STAT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_PUR_PO_ITM_ORDR_STAT_T
(
OLE_PO_ITM_ORDR_STAT_ID NUMBER(8)
, OLE_PO_ITM_ORDR_STAT VARCHAR2(100) NOT NULL
, VER_NBR NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, DESC_TXT VARCHAR2(500) NOT NULL
)
/
ALTER TABLE OLE_PUR_PO_ITM_ORDR_STAT_T
ADD CONSTRAINT OLE_PUR_PO_ITM_ORDR_STAT_TP1
PRIMARY KEY (OLE_PO_ITM_ORDR_STAT_ID)
/
-----------------------------------------------------------------------------
-- OLE_PUR_PO_LOAD_SUM_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_PUR_PO_LOAD_SUM_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_PUR_PO_LOAD_SUM_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_PUR_PO_LOAD_SUM_T
(
PO_LOAD_SUM_ID NUMBER(10)
, PRNCPL_ID VARCHAR2(45) NOT NULL
, PO_LOAD_SCCSS_CNT NUMBER(5) NOT NULL
, PO_LOAD_FAIL_CNT NUMBER(5) NOT NULL
, PO_LOAD_TOT NUMBER(5) NOT NULL
, PO_LOAD_PO_TOT NUMBER(5) NOT NULL
, PO_LOAD_DESC VARCHAR2(2000)
, FILE_NM VARCHAR2(200) NOT NULL
, BAT_PRCS_PRF_ID VARCHAR2(40)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) NOT NULL
, FDOC_NBR VARCHAR2(14) NOT NULL
, EDI_FILE_NM VARCHAR2(200)
, PO_LOAD_CREATE_DATE TIMESTAMP
)
/
ALTER TABLE OLE_PUR_PO_LOAD_SUM_T
ADD CONSTRAINT OLE_PUR_PO_LOAD_SUM_TP1
PRIMARY KEY (PO_LOAD_SUM_ID)
/
-----------------------------------------------------------------------------
-- OLE_PUR_PO_PRFL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_PUR_PO_PRFL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_PUR_PO_PRFL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_PUR_PO_PRFL_T
(
PRFL_ID NUMBER(10)
, PRFL_NM VARCHAR2(200) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) NOT NULL
, ROW_ACT_IND VARCHAR2(1) NOT NULL
)
/
ALTER TABLE OLE_PUR_PO_PRFL_T
ADD CONSTRAINT OLE_PUR_PO_PRFL_TP1
PRIMARY KEY (PRFL_ID)
/
-----------------------------------------------------------------------------
-- OLE_PUR_PO_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_PUR_PO_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_PUR_PO_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_PUR_PO_TYP_T
(
OLE_PO_TYPE_ID NUMBER(8)
, OLE_PO_TYPE VARCHAR2(250) NOT NULL
, VER_NBR NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
, ROW_ACT_IND VARCHAR2(1) NOT NULL
, DESC_TXT VARCHAR2(1000)
)
/
ALTER TABLE OLE_PUR_PO_TYP_T
ADD CONSTRAINT OLE_PUR_PO_TYP_TP1
PRIMARY KEY (OLE_PO_TYPE_ID)
/
-----------------------------------------------------------------------------
-- OLE_PUR_RCVNG_COR_LN_ITM_DOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_PUR_RCVNG_COR_LN_ITM_DOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_PUR_RCVNG_COR_LN_ITM_DOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_PUR_RCVNG_COR_LN_ITM_DOC_T
(
OLE_PUR_RCVNG_LN_ITM_DOC_ID NUMBER(10)
, RCVNG_COR_ITM_ID NUMBER(10)
, OLE_DOCUMENT_UUID VARCHAR2(50) NOT NULL
, VER_NBR NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36)
)
/
ALTER TABLE OLE_PUR_RCVNG_COR_LN_ITM_DOC_T
ADD CONSTRAINT OLE_PUR_RCVNG_COR_LN_ITM_DOP1
PRIMARY KEY (OLE_PUR_RCVNG_LN_ITM_DOC_ID,RCVNG_COR_ITM_ID)
/
-----------------------------------------------------------------------------
-- OLE_PUR_RCVNG_COR_LN_ITM_EXC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_PUR_RCVNG_COR_LN_ITM_EXC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_PUR_RCVNG_COR_LN_ITM_EXC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_PUR_RCVNG_COR_LN_ITM_EXC_T
(
OLE_RCVNG_COR_LN_ITM_EXC_ID NUMBER(10)
, RCVNG_LN_ITM_ID NUMBER(10)
, OLE_RCVNG_LN_ITM_EXC_MDOC_ID NUMBER(8) NOT NULL
, OLE_COR_EXC_NTE VARCHAR2(2000) NOT NULL
, VER_NBR NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
)
/
ALTER TABLE OLE_PUR_RCVNG_COR_LN_ITM_EXC_T
ADD CONSTRAINT OLE_PUR_RCVNG_COR_LN_ITM_EXP1
PRIMARY KEY (OLE_RCVNG_COR_LN_ITM_EXC_ID,RCVNG_LN_ITM_ID)
/
-----------------------------------------------------------------------------
-- OLE_PUR_RCVNG_COR_LN_ITM_NTE_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_PUR_RCVNG_COR_LN_ITM_NTE_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_PUR_RCVNG_COR_LN_ITM_NTE_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_PUR_RCVNG_COR_LN_ITM_NTE_T
(
OLE_RCVNG_COR_LN_ITM_NTE_ID NUMBER(10)
, RCVNG_COR_ITM_ID NUMBER(10)
, OLE_NTE VARCHAR2(2000) NOT NULL
, OLE_NTE_TYP_ID NUMBER(10)
, VER_NBR NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
)
/
ALTER TABLE OLE_PUR_RCVNG_COR_LN_ITM_NTE_T
ADD CONSTRAINT OLE_PUR_RCVNG_COR_LN_ITM_NTP1
PRIMARY KEY (OLE_RCVNG_COR_LN_ITM_NTE_ID,RCVNG_COR_ITM_ID)
/
-----------------------------------------------------------------------------
-- OLE_PUR_RCVNG_LN_ITM_DOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_PUR_RCVNG_LN_ITM_DOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_PUR_RCVNG_LN_ITM_DOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_PUR_RCVNG_LN_ITM_DOC_T
(
OLE_PUR_RCVNG_LN_ITM_DOC_ID NUMBER(10)
, RCVNG_LN_ITM_ID NUMBER(10)
, OLE_DOCUMENT_UUID VARCHAR2(50) NOT NULL
)
/
ALTER TABLE OLE_PUR_RCVNG_LN_ITM_DOC_T
ADD CONSTRAINT OLE_PUR_RCVNG_LN_ITM_DOC_TP1
PRIMARY KEY (OLE_PUR_RCVNG_LN_ITM_DOC_ID,RCVNG_LN_ITM_ID)
/
-----------------------------------------------------------------------------
-- OLE_PUR_RCVNG_LN_ITM_EXC_MDC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_PUR_RCVNG_LN_ITM_EXC_MDC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_PUR_RCVNG_LN_ITM_EXC_MDC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_PUR_RCVNG_LN_ITM_EXC_MDC_T
(
OLE_RCVNG_LN_ITM_EXC_MDOC_ID NUMBER(8)
, OLE_RCVNG_LN_ITM_EXC VARCHAR2(100) NOT NULL
, VER_NBR NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
, ROW_ACT_IND VARCHAR2(1) NOT NULL
)
/
ALTER TABLE OLE_PUR_RCVNG_LN_ITM_EXC_MDC_T
ADD CONSTRAINT OLE_PUR_RCVNG_LN_ITM_EXC_MDP1
PRIMARY KEY (OLE_RCVNG_LN_ITM_EXC_MDOC_ID)
/
-----------------------------------------------------------------------------
-- OLE_PUR_RCVNG_LN_ITM_EXC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_PUR_RCVNG_LN_ITM_EXC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_PUR_RCVNG_LN_ITM_EXC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_PUR_RCVNG_LN_ITM_EXC_T
(
OLE_PUR_RCVNG_LN_ITM_EXC_ID NUMBER(10)
, RCVNG_LN_ITM_ID NUMBER(10)
, OLE_RCVNG_LN_ITM_EXC_MDOC_ID NUMBER(8) NOT NULL
, OLE_EXC_NTE VARCHAR2(2000)
, VER_NBR NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
)
/
ALTER TABLE OLE_PUR_RCVNG_LN_ITM_EXC_T
ADD CONSTRAINT OLE_PUR_RCVNG_LN_ITM_EXC_TP1
PRIMARY KEY (OLE_PUR_RCVNG_LN_ITM_EXC_ID,RCVNG_LN_ITM_ID)
/
-----------------------------------------------------------------------------
-- OLE_PUR_RCVNG_LN_ITM_NTE_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_PUR_RCVNG_LN_ITM_NTE_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_PUR_RCVNG_LN_ITM_NTE_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_PUR_RCVNG_LN_ITM_NTE_T
(
OLE_RCVNG_LN_ITM_NTE_ID NUMBER(10)
, RCVNG_LN_ITM_ID NUMBER(10)
, OLE_NTE VARCHAR2(2000) NOT NULL
, OLE_NTE_TYP_ID NUMBER(10)
, VER_NBR NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
)
/
ALTER TABLE OLE_PUR_RCVNG_LN_ITM_NTE_T
ADD CONSTRAINT OLE_PUR_RCVNG_LN_ITM_NTE_TP1
PRIMARY KEY (OLE_RCVNG_LN_ITM_NTE_ID,RCVNG_LN_ITM_ID)
/
-----------------------------------------------------------------------------
-- OLE_PUR_REQS_ITM_T_NTE_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_PUR_REQS_ITM_T_NTE_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_PUR_REQS_ITM_T_NTE_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_PUR_REQS_ITM_T_NTE_T
(
OLE_REQ_ITM_NTE_ID NUMBER(10)
, REQS_ITM_ID NUMBER(10)
, OLE_NTE VARCHAR2(2000) NOT NULL
, OLE_NTE_TYP_ID NUMBER(10)
, VER_NBR NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
)
/
ALTER TABLE OLE_PUR_REQS_ITM_T_NTE_T
ADD CONSTRAINT OLE_PUR_REQS_ITM_T_NTE_TP1
PRIMARY KEY (OLE_REQ_ITM_NTE_ID,REQS_ITM_ID)
/
-----------------------------------------------------------------------------
-- OLE_PUR_REQ_RCPT_STATUS_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_PUR_REQ_RCPT_STATUS_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_PUR_REQ_RCPT_STATUS_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_PUR_REQ_RCPT_STATUS_T
(
OLE_REQ_RCPT_STATUS_ID NUMBER(10)
, OLE_REQ_RCPT_STATUS_DOC_TYP VARCHAR2(200) NOT NULL
, OLE_REQ_RCPT_STATUS_CD VARCHAR2(100) NOT NULL
, OLE_REQ_RCPT_STATUS_NM VARCHAR2(200) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) NOT NULL
, ROW_ACT_IND VARCHAR2(1) NOT NULL
, CONSTRAINT OLE_REQ_RCPT_STS_CD_TC0 UNIQUE (OLE_REQ_RCPT_STATUS_DOC_TYP, OLE_REQ_RCPT_STATUS_CD)
)
/
ALTER TABLE OLE_PUR_REQ_RCPT_STATUS_T
ADD CONSTRAINT OLE_PUR_REQ_RCPT_STATUS_TP1
PRIMARY KEY (OLE_REQ_RCPT_STATUS_ID)
/
-----------------------------------------------------------------------------
-- OLE_PUR_REQ_SRC_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_PUR_REQ_SRC_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_PUR_REQ_SRC_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_PUR_REQ_SRC_TYP_T
(
OLE_REQ_SRC_TYP_ID NUMBER(8)
, OLE_REQ_SRC_TYPE VARCHAR2(45)
, VER_NBR NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
, ROW_ACTV_IND VARCHAR2(1)
)
/
ALTER TABLE OLE_PUR_REQ_SRC_TYP_T
ADD CONSTRAINT OLE_PUR_REQ_SRC_TYP_TP1
PRIMARY KEY (OLE_REQ_SRC_TYP_ID)
/
-----------------------------------------------------------------------------
-- OLE_RQSTR_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_RQSTR_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_RQSTR_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_RQSTR_TYP_T
(
OLE_RQSTR_TYP_ID NUMBER(8)
, OLE_RQSTR_TYP VARCHAR2(100)
, VER_NBR NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
, ROW_ACTV_IND VARCHAR2(1)
)
/
ALTER TABLE OLE_RQSTR_TYP_T
ADD CONSTRAINT OLE_RQSTR_TYP_TP1
PRIMARY KEY (OLE_RQSTR_TYP_ID)
/
-----------------------------------------------------------------------------
-- OLE_VNDR_ALIAS_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_VNDR_ALIAS_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_VNDR_ALIAS_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_VNDR_ALIAS_TYP_T
(
OLE_ALIAS_TYP_ID NUMBER(8)
, OLE_ALIAS_TYP VARCHAR2(100) NOT NULL
, VER_NBR NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
, ROW_ACT_IND VARCHAR2(1) NOT NULL
, DESC_TXT VARCHAR2(500)
)
/
ALTER TABLE OLE_VNDR_ALIAS_TYP_T
ADD CONSTRAINT OLE_VNDR_ALIAS_TYP_TP1
PRIMARY KEY (OLE_ALIAS_TYP_ID)
/
-----------------------------------------------------------------------------
-- OLE_VNDR_TRANS_FRMT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_VNDR_TRANS_FRMT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_VNDR_TRANS_FRMT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_VNDR_TRANS_FRMT_T
(
OLE_VNDR_TRANS_FRMT_ID NUMBER(8)
, OLE_VNDR_TRANS_FRMT VARCHAR2(200) NOT NULL
, VER_NBR NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
, ROW_ACT_IND VARCHAR2(1) NOT NULL
)
/
ALTER TABLE OLE_VNDR_TRANS_FRMT_T
ADD CONSTRAINT OLE_VNDR_TRANS_FRMT_TP1
PRIMARY KEY (OLE_VNDR_TRANS_FRMT_ID)
/
-----------------------------------------------------------------------------
-- OLE_VNDR_TRANS_FRMT_TYP_INT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_VNDR_TRANS_FRMT_TYP_INT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_VNDR_TRANS_FRMT_TYP_INT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_VNDR_TRANS_FRMT_TYP_INT_T
(
VNDR_DTL_ASND_ID NUMBER(10)
, VNDR_HDR_GNRTD_ID NUMBER(10)
, OLE_VNDR_TRANS_FRMT_ID NUMBER(8)
, OLE_PRF_TRANS_FRMT_TYP VARCHAR2(1) NOT NULL
, OLE_TRANS_TYP_ADD VARCHAR2(700)
, OLE_TRANS_USR_NM VARCHAR2(45)
, OLE_TRANS_PW VARCHAR2(45)
, VER_NBR NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
, ROW_ACT_IND VARCHAR2(1) NOT NULL
, OLE_TRANS_TYP_ID NUMBER(10)
)
/
ALTER TABLE OLE_VNDR_TRANS_FRMT_TYP_INT_T
ADD CONSTRAINT OLE_VNDR_TRANS_FRMT_TYP_INTP1
PRIMARY KEY (VNDR_DTL_ASND_ID,VNDR_HDR_GNRTD_ID,OLE_VNDR_TRANS_FRMT_ID,OLE_TRANS_TYP_ID)
/
-----------------------------------------------------------------------------
-- OLE_VNDR_TRANS_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_VNDR_TRANS_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_VNDR_TRANS_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_VNDR_TRANS_TYP_T
(
OLE_TRANS_TYP_ID NUMBER(10)
, VER_NBR NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
, OLE_TRANS_TYP VARCHAR2(45)
, ROW_ACT_IND VARCHAR2(1)
)
/
ALTER TABLE OLE_VNDR_TRANS_TYP_T
ADD CONSTRAINT OLE_VNDR_TRANS_TYP_TP1
PRIMARY KEY (OLE_TRANS_TYP_ID)
/
-----------------------------------------------------------------------------
-- OLE_LIC_REQ_DET_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_LIC_REQ_DET_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_LIC_REQ_DET_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_LIC_REQ_DET_T
(
OLE_LIC_REQ_DET_ID NUMBER(10)
, VER_NBR NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
, OLE_REQ_DOC_NUM VARCHAR2(14)
, OLE_LIC_DOC_NUM VARCHAR2(14)
)
/
ALTER TABLE OLE_LIC_REQ_DET_T
ADD CONSTRAINT OLE_LIC_REQ_DET_TP1
PRIMARY KEY (OLE_LIC_REQ_DET_ID)
/
-----------------------------------------------------------------------------
-- PDP_ACCTG_CHG_CD_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PDP_ACCTG_CHG_CD_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PDP_ACCTG_CHG_CD_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PDP_ACCTG_CHG_CD_T
(
ACCTG_CHG_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36)
, VER_NBR NUMBER(8) default 1 NOT NULL
, ACCTG_CHG_CD_DESC VARCHAR2(50) NOT NULL
)
/
ALTER TABLE PDP_ACCTG_CHG_CD_T
ADD CONSTRAINT PDP_ACCTG_CHG_CD_TP1
PRIMARY KEY (ACCTG_CHG_CD)
/
-----------------------------------------------------------------------------
-- PDP_ACH_ACCT_NBR_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PDP_ACH_ACCT_NBR_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PDP_ACH_ACCT_NBR_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PDP_ACH_ACCT_NBR_T
(
PMT_GRP_ID NUMBER(8)
, OBJ_ID VARCHAR2(36)
, VER_NBR NUMBER(8) default 1 NOT NULL
, ACH_BNK_ACCT_NBR VARCHAR2(255)
, LST_UPDT_TS DATE NOT NULL
)
/
ALTER TABLE PDP_ACH_ACCT_NBR_T
ADD CONSTRAINT PDP_ACH_ACCT_NBR_TP1
PRIMARY KEY (PMT_GRP_ID)
/
-----------------------------------------------------------------------------
-- PDP_ACH_BNK_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PDP_ACH_BNK_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PDP_ACH_BNK_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PDP_ACH_BNK_T
(
BNK_RTNG_NBR VARCHAR2(9)
, OBJ_ID VARCHAR2(36)
, VER_NBR NUMBER(8) default 1 NOT NULL
, BNK_OFFC_CD VARCHAR2(1)
, BNK_SRVC_NBR VARCHAR2(9)
, BNK_TYP_CD VARCHAR2(1)
, BNK_NEW_RTNG_NBR VARCHAR2(9)
, BNK_NM VARCHAR2(40)
, BNK_STR_ADDR VARCHAR2(45)
, BNK_CTY_NM VARCHAR2(50)
, BNK_ST_CD VARCHAR2(2)
, BNK_ZIP_CD VARCHAR2(20)
, BNK_PHN_AREA_CD VARCHAR2(3)
, BNK_PHN_PRFX_NBR VARCHAR2(3)
, BNK_PHN_SFX_NBR VARCHAR2(4)
, BNK_INST_STAT_CD VARCHAR2(1)
, BNK_DTA_V_CD VARCHAR2(1)
, ACTV_IND VARCHAR2(1) default 'Y' NOT NULL
)
/
ALTER TABLE PDP_ACH_BNK_T
ADD CONSTRAINT PDP_ACH_BNK_TP1
PRIMARY KEY (BNK_RTNG_NBR)
/
-----------------------------------------------------------------------------
-- PDP_ACH_TRANS_CD_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PDP_ACH_TRANS_CD_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PDP_ACH_TRANS_CD_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PDP_ACH_TRANS_CD_T
(
TRANS_CD VARCHAR2(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, TRANS_DESC VARCHAR2(100)
, CONSTRAINT PDP_ACH_TRANS_CD_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PDP_ACH_TRANS_CD_T
ADD CONSTRAINT PDP_ACH_TRANS_CD_TP1
PRIMARY KEY (TRANS_CD)
/
-----------------------------------------------------------------------------
-- PDP_ACH_TRANS_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PDP_ACH_TRANS_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PDP_ACH_TRANS_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PDP_ACH_TRANS_TYP_T
(
TRANS_TYP VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, TRANS_TYP_DESC VARCHAR2(50) NOT NULL
, CONSTRAINT PDP_ACH_TRANS_TYP_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PDP_ACH_TRANS_TYP_T
ADD CONSTRAINT PDP_ACH_TRANS_TYP_TP1
PRIMARY KEY (TRANS_TYP)
/
-----------------------------------------------------------------------------
-- PDP_CUST_BNK_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PDP_CUST_BNK_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PDP_CUST_BNK_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PDP_CUST_BNK_T
(
CUST_ID NUMBER(8)
, DISB_TYP_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, BNK_CD VARCHAR2(4) NOT NULL
, ACTV_IND VARCHAR2(1) default 'Y' NOT NULL
, CONSTRAINT PDP_CUST_BNK_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PDP_CUST_BNK_T
ADD CONSTRAINT PDP_CUST_BNK_TP1
PRIMARY KEY (CUST_ID,DISB_TYP_CD)
/
-----------------------------------------------------------------------------
-- PDP_CUST_PRFL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PDP_CUST_PRFL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PDP_CUST_PRFL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PDP_CUST_PRFL_T
(
CUST_ID NUMBER(8)
, OBJ_ID VARCHAR2(36)
, VER_NBR NUMBER(8) default 1 NOT NULL
, FIN_COA_CD VARCHAR2(2) NOT NULL
, UNT_CD VARCHAR2(4) NOT NULL
, SBUNT_CD VARCHAR2(4) NOT NULL
, CUST_DESC VARCHAR2(50)
, CUST_ACTV_IND VARCHAR2(1)
, CUST_PRCS_EMAIL_ADDR VARCHAR2(200)
, PMT_THRSHLD_AMT NUMBER(19,2)
, CUST_PMT_THRSHLD_EMAIL_ADDR VARCHAR2(200)
, FL_THRSHLD_AMT NUMBER(19,2)
, CUST_FILE_THRSHLD_EMAIL_ADDR VARCHAR2(200)
, DFLT_COA_CD VARCHAR2(2) NOT NULL
, DFLT_ACCT_NBR VARCHAR2(7) NOT NULL
, DFLT_SUB_ACCT_NBR VARCHAR2(5) NOT NULL
, DFLT_OBJ_CD VARCHAR2(4) NOT NULL
, DFLT_SUB_OBJ_CD VARCHAR2(3) NOT NULL
, ADV_CRTE_IND VARCHAR2(1)
, ACH_PMT_DESC VARCHAR2(100)
, ACH_TRANS_TYP VARCHAR2(4)
, CUST_CNTC_FULL_NM VARCHAR2(123)
, CUST_LN1_ADDR VARCHAR2(55)
, CUST_LN2_ADDR VARCHAR2(55)
, CUST_LN3_ADDR VARCHAR2(55)
, CUST_LN4_ADDR VARCHAR2(55)
, CUST_CTY_NM VARCHAR2(50)
, CUST_ST_CD VARCHAR2(2)
, CUST_ZIP_CD VARCHAR2(20)
, CUST_CNTRY_CD VARCHAR2(10)
, CHK_HDR_NTE_LN1_TXT VARCHAR2(90)
, CHK_HDR_NTE_LN2_TXT VARCHAR2(90)
, CHK_HDR_NTE_LN3_TXT VARCHAR2(90)
, CHK_HDR_NTE_LN4_TXT VARCHAR2(90)
, ADDL_CHK_NTE_LN1_TXT VARCHAR2(90)
, ADDL_CHK_NTE_LN2_TXT VARCHAR2(90)
, ADDL_CHK_NTE_LN3_TXT VARCHAR2(90)
, ADDL_CHK_NTE_LN4_TXT VARCHAR2(90)
, ADV_HDR_TXT VARCHAR2(400)
, ADV_SUBJ_LN_TXT VARCHAR2(40)
, ADV_RTRN_EMAIL_ADDR VARCHAR2(200)
, DFLT_PHYS_CMP_PROC_CD VARCHAR2(2)
, CUST_NRA_RVW_IND VARCHAR2(1) NOT NULL
, ACCTG_EDIT_REQ_IND VARCHAR2(1) NOT NULL
, CUST_EMP_CHK_IND VARCHAR2(1) NOT NULL
, CUST_OWNR_CD_REQ_IND VARCHAR2(1) NOT NULL
, CUST_PAYEE_ID_REQ_IND VARCHAR2(1) NOT NULL
, FIN_OBJECT_CD_LBLTY_RLF_CD VARCHAR2(1)
, ACTV_IND VARCHAR2(1) default 'Y' NOT NULL
, CONSTRAINT PDP_CUST_PRFL_TC1 UNIQUE (FIN_COA_CD, UNT_CD, SBUNT_CD)
)
/
ALTER TABLE PDP_CUST_PRFL_T
ADD CONSTRAINT PDP_CUST_PRFL_TP1
PRIMARY KEY (CUST_ID)
/
-----------------------------------------------------------------------------
-- PDP_DISB_NBR_RNG_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PDP_DISB_NBR_RNG_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PDP_DISB_NBR_RNG_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PDP_DISB_NBR_RNG_T
(
OBJ_ID VARCHAR2(36)
, VER_NBR NUMBER(8) default 1 NOT NULL
, PHYS_CMP_PROC_CD VARCHAR2(2)
, BEG_DISB_NBR NUMBER(9) NOT NULL
, LST_ASND_DISB_NBR NUMBER(9) NOT NULL
, END_DISB_NBR NUMBER(9) NOT NULL
, DISB_NBR_RNG_START_DT DATE
, BNK_CD VARCHAR2(4)
, DISB_TYP_CD VARCHAR2(4)
, ACTV_IND VARCHAR2(1) default 'Y' NOT NULL
)
/
ALTER TABLE PDP_DISB_NBR_RNG_T
ADD CONSTRAINT PDP_DISB_NBR_RNG_TP1
PRIMARY KEY (PHYS_CMP_PROC_CD,DISB_NBR_RNG_START_DT,BNK_CD,DISB_TYP_CD)
/
-----------------------------------------------------------------------------
-- PDP_DISB_TYP_CD_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PDP_DISB_TYP_CD_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PDP_DISB_TYP_CD_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PDP_DISB_TYP_CD_T
(
DISB_TYP_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36)
, VER_NBR NUMBER(8) default 1 NOT NULL
, DISB_TYP_DESC VARCHAR2(25) NOT NULL
)
/
ALTER TABLE PDP_DISB_TYP_CD_T
ADD CONSTRAINT PDP_DISB_TYP_CD_TP1
PRIMARY KEY (DISB_TYP_CD)
/
-----------------------------------------------------------------------------
-- PDP_FIL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PDP_FIL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PDP_FIL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PDP_FIL_T
(
PMT_FIL_ID NUMBER(8)
, OBJ_ID VARCHAR2(36)
, VER_NBR NUMBER(8) default 1 NOT NULL
, PMT_FL_NM VARCHAR2(30)
, CUST_FL_CRTN_TS DATE
, PMT_CNT NUMBER(5)
, PMT_TOT_AMT NUMBER(19,2)
, SBMTR_USR_ID VARCHAR2(40)
, FL_PROC_TS DATE
, CUST_ID NUMBER(8)
, LST_UPDT_TS DATE NOT NULL
)
/
ALTER TABLE PDP_FIL_T
ADD CONSTRAINT PDP_FIL_TP1
PRIMARY KEY (PMT_FIL_ID)
/
CREATE INDEX PDP_FIL_TI2
ON PDP_FIL_T
(CUST_ID)
/
-----------------------------------------------------------------------------
-- PDP_FMT_PROC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PDP_FMT_PROC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PDP_FMT_PROC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PDP_FMT_PROC_T
(
PHYS_CMP_PROC_CD VARCHAR2(2)
, OBJ_ID VARCHAR2(36)
, VER_NBR NUMBER(8) default 1 NOT NULL
, BEG_PROC_TS DATE NOT NULL
, LST_UPDT_TS DATE NOT NULL
, PMT_PROC_ID NUMBER(8)
)
/
ALTER TABLE PDP_FMT_PROC_T
ADD CONSTRAINT PDP_FMT_PROC_TP1
PRIMARY KEY (PHYS_CMP_PROC_CD)
/
-----------------------------------------------------------------------------
-- PDP_GL_PENDING_ENTRY_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PDP_GL_PENDING_ENTRY_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PDP_GL_PENDING_ENTRY_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PDP_GL_PENDING_ENTRY_T
(
GL_PENDING_ENTRY_ID NUMBER(8)
, OBJ_ID VARCHAR2(36)
, VER_NBR NUMBER(8) default 1 NOT NULL
, FS_ORIGIN_CD VARCHAR2(2) NOT NULL
, FDOC_NBR VARCHAR2(14) NOT NULL
, TRN_ENTR_SEQ_NBR NUMBER(5)
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, SUB_ACCOUNT_NBR VARCHAR2(5)
, FIN_OBJECT_CD VARCHAR2(4)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, FIN_BALANCE_TYP_CD VARCHAR2(2)
, FIN_OBJ_TYP_CD VARCHAR2(2)
, UNIV_FISCAL_YR NUMBER(4)
, UNIV_FISCAL_PRD_CD VARCHAR2(2)
, TRN_LDGR_ENTR_DESC VARCHAR2(40)
, TRN_LDGR_ENTR_AMT NUMBER(19,2)
, TRN_DEBIT_CRDT_CD VARCHAR2(1)
, TRANSACTION_DT DATE
, FDOC_TYP_CD VARCHAR2(8)
, ORG_DOC_NBR VARCHAR2(10)
, PROJECT_CD VARCHAR2(10)
, ORG_REFERENCE_ID VARCHAR2(8)
, FDOC_REF_TYP_CD VARCHAR2(8)
, FS_REF_ORIGIN_CD VARCHAR2(2)
, FDOC_REF_NBR VARCHAR2(14)
, FDOC_REVERSAL_DT DATE
, TRN_ENCUM_UPDT_CD VARCHAR2(1)
, FDOC_APPROVED_CD VARCHAR2(1)
, ACCT_SF_FINOBJ_CD VARCHAR2(4)
, TRN_ENTR_OFST_CD VARCHAR2(1)
, TRN_EXTRT_IND VARCHAR2(1) default 'N' NOT NULL
)
/
ALTER TABLE PDP_GL_PENDING_ENTRY_T
ADD CONSTRAINT PDP_GL_PENDING_ENTRY_TP1
PRIMARY KEY (GL_PENDING_ENTRY_ID)
/
-----------------------------------------------------------------------------
-- PDP_PAYEE_ACH_ACCT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PDP_PAYEE_ACH_ACCT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PDP_PAYEE_ACH_ACCT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PDP_PAYEE_ACH_ACCT_T
(
ACH_ACCT_GNRTD_ID NUMBER(10)
, OBJ_ID VARCHAR2(36)
, VER_NBR NUMBER(8) default 1 NOT NULL
, BNK_RTNG_NBR VARCHAR2(9)
, BNK_ACCT_NBR VARCHAR2(255)
, PAYEE_NM VARCHAR2(123)
, PAYEE_EMAIL_ADDR VARCHAR2(200)
, PAYEE_ID_TYP_CD VARCHAR2(1)
, ACH_TRANS_TYP VARCHAR2(4)
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, BNK_ACCT_TYP_CD VARCHAR2(2)
, PAYEE_ID_NBR VARCHAR2(40) default '1' NOT NULL
)
/
ALTER TABLE PDP_PAYEE_ACH_ACCT_T
ADD CONSTRAINT PDP_PAYEE_ACH_ACCT_TP1
PRIMARY KEY (ACH_ACCT_GNRTD_ID)
/
-----------------------------------------------------------------------------
-- PDP_PAYEE_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PDP_PAYEE_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PDP_PAYEE_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PDP_PAYEE_TYP_T
(
PAYEE_TYP_CD VARCHAR2(1)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, PAYEE_TYP_DESC VARCHAR2(40) NOT NULL
, ACH_ELGBL_IND VARCHAR2(1) default 'N'
, CONSTRAINT PDP_PAYEE_TYP_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PDP_PAYEE_TYP_T
ADD CONSTRAINT PDP_PAYEE_TYP_TP1
PRIMARY KEY (PAYEE_TYP_CD)
/
-----------------------------------------------------------------------------
-- PDP_PMT_ACCT_DTL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PDP_PMT_ACCT_DTL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PDP_PMT_ACCT_DTL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PDP_PMT_ACCT_DTL_T
(
PMT_ACCT_DTL_ID NUMBER(8)
, OBJ_ID VARCHAR2(36)
, VER_NBR NUMBER(8) default 1 NOT NULL
, FIN_COA_CD VARCHAR2(2) NOT NULL
, ACCOUNT_NBR VARCHAR2(7) NOT NULL
, SUB_ACCT_NBR VARCHAR2(5) NOT NULL
, FIN_SUB_OBJ_CD VARCHAR2(3) NOT NULL
, FIN_OBJECT_CD VARCHAR2(4) NOT NULL
, ORG_REFERENCE_ID VARCHAR2(8)
, PROJECT_CD VARCHAR2(10) NOT NULL
, ACCT_NET_AMT NUMBER(19,2) NOT NULL
, PMT_DTL_ID NUMBER(8) NOT NULL
, LST_UPDT_TS DATE NOT NULL
)
/
ALTER TABLE PDP_PMT_ACCT_DTL_T
ADD CONSTRAINT PDP_PMT_ACCT_DTL_TP1
PRIMARY KEY (PMT_ACCT_DTL_ID)
/
CREATE INDEX PDP_PMT_ACCT_DTL_TI2
ON PDP_PMT_ACCT_DTL_T
(PMT_DTL_ID)
/
-----------------------------------------------------------------------------
-- PDP_PMT_ACCT_HIST_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PDP_PMT_ACCT_HIST_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PDP_PMT_ACCT_HIST_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PDP_PMT_ACCT_HIST_T
(
PMT_ACCT_HIST_ID NUMBER(8)
, OBJ_ID VARCHAR2(36)
, VER_NBR NUMBER(8) default 1 NOT NULL
, ACCTG_CHG_CD VARCHAR2(4)
, ACCT_ATTRIB_NM VARCHAR2(25)
, ACCT_ATTRIB_ORIG_VAL VARCHAR2(15)
, ACCT_ATTRIB_NEW_VAL VARCHAR2(15)
, ACCT_CHG_TS DATE
, PMT_ACCT_DTL_ID NUMBER(8)
, LST_UPDT_TS DATE NOT NULL
)
/
ALTER TABLE PDP_PMT_ACCT_HIST_T
ADD CONSTRAINT PDP_PMT_ACCT_HIST_TP1
PRIMARY KEY (PMT_ACCT_HIST_ID)
/
CREATE INDEX PDP_PMT_ACCT_HIST_TI2
ON PDP_PMT_ACCT_HIST_T
(PMT_ACCT_DTL_ID)
/
CREATE INDEX PDP_PMT_ACCT_HIST_TI3
ON PDP_PMT_ACCT_HIST_T
(ACCTG_CHG_CD)
/
-----------------------------------------------------------------------------
-- PDP_PMT_CHG_CD_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PDP_PMT_CHG_CD_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PDP_PMT_CHG_CD_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PDP_PMT_CHG_CD_T
(
PMT_CHG_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36)
, VER_NBR NUMBER(8) default 1 NOT NULL
, PMT_CHG_CD_DESC VARCHAR2(50) NOT NULL
)
/
ALTER TABLE PDP_PMT_CHG_CD_T
ADD CONSTRAINT PDP_PMT_CHG_CD_TP1
PRIMARY KEY (PMT_CHG_CD)
/
-----------------------------------------------------------------------------
-- PDP_PMT_DTL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PDP_PMT_DTL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PDP_PMT_DTL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PDP_PMT_DTL_T
(
PMT_DTL_ID NUMBER(8)
, OBJ_ID VARCHAR2(36)
, VER_NBR NUMBER(8) default 1 NOT NULL
, CUST_PMT_DOC_NBR VARCHAR2(14)
, LST_UPDT_TS DATE NOT NULL
, INV_NBR VARCHAR2(25)
, PO_NBR VARCHAR2(9)
, INV_DT DATE NOT NULL
, PMT_GRP_ID NUMBER(8)
, REQS_NBR VARCHAR2(8)
, ORG_DOC_NBR VARCHAR2(10)
, ORIG_INV_AMT NUMBER(19,2) NOT NULL
, NET_PMT_AMT NUMBER(19,2) NOT NULL
, INV_TOT_DSCT_AMT NUMBER(14,2) NOT NULL
, INV_TOT_SHP_AMT NUMBER(19,2) NOT NULL
, INV_TOT_OTHR_DEBIT_AMT NUMBER(19,2) NOT NULL
, INV_TOT_OTHR_CRDT_AMT NUMBER(19,2) NOT NULL
, PDP_PRM_PMT_CNCL_IND VARCHAR2(1)
, FDOC_TYP_CD VARCHAR2(8)
, FS_ORIGIN_CD VARCHAR2(2)
, CUST_INST_NBR VARCHAR2(30)
, OLE_PMT_MTHD_CDE VARCHAR2(100)
)
/
ALTER TABLE PDP_PMT_DTL_T
ADD CONSTRAINT PDP_PMT_DTL_TP1
PRIMARY KEY (PMT_DTL_ID)
/
CREATE INDEX PDP_PMT_DTL_TI2
ON PDP_PMT_DTL_T
(PMT_GRP_ID)
/
CREATE INDEX PDP_PMT_DTL_TI3
ON PDP_PMT_DTL_T
(CUST_PMT_DOC_NBR)
/
-----------------------------------------------------------------------------
-- PDP_PMT_GRP_HIST_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PDP_PMT_GRP_HIST_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PDP_PMT_GRP_HIST_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PDP_PMT_GRP_HIST_T
(
PMT_GRP_HIST_ID NUMBER(8)
, OBJ_ID VARCHAR2(36)
, VER_NBR NUMBER(8) default 1 NOT NULL
, PMT_CHG_CD VARCHAR2(4)
, PMT_CHG_NTE_TXT VARCHAR2(250)
, PMT_CHG_USR_ID VARCHAR2(40)
, PMT_CHG_TS DATE
, ORIG_PMT_STAT_CD VARCHAR2(4)
, ORIG_PMT_DT DATE
, ORIG_ACH_BNK_RTNG_NBR VARCHAR2(9)
, ORIG_ADV_EMAIL_ADDR VARCHAR2(50)
, ORIG_DISB_NBR NUMBER(9)
, ORIG_DISB_TS DATE
, ORIG_PROC_IMD_IND VARCHAR2(1)
, ORIG_PMT_SPCL_HANDLG_IND VARCHAR2(1)
, PMT_CNCL_EXTRT_TS DATE
, ORIG_DISB_TYP_CD VARCHAR2(4)
, PMT_CNCL_EXTRT_STAT_IND VARCHAR2(1)
, ORIG_PROC_ID NUMBER(8)
, PMT_GRP_ID NUMBER(8)
, LST_UPDT_TS DATE NOT NULL
, ORIG_BNK_CD VARCHAR2(4)
)
/
ALTER TABLE PDP_PMT_GRP_HIST_T
ADD CONSTRAINT PDP_PMT_GRP_HIST_TP1
PRIMARY KEY (PMT_GRP_HIST_ID)
/
CREATE INDEX PDP_PMT_GRP_HIST_TI3
ON PDP_PMT_GRP_HIST_T
(ORIG_PMT_STAT_CD)
/
CREATE INDEX PDP_PMT_GRP_HIST_TI4
ON PDP_PMT_GRP_HIST_T
(PMT_CHG_CD)
/
CREATE INDEX PDP_PMT_GRP_HIST_TI6
ON PDP_PMT_GRP_HIST_T
(ORIG_DISB_TYP_CD)
/
CREATE INDEX PDP_PMT_GRP_HIST_TI7
ON PDP_PMT_GRP_HIST_T
(ORIG_PROC_ID)
/
CREATE INDEX PDP_PMT_GRP_HIST_TI8
ON PDP_PMT_GRP_HIST_T
(PMT_GRP_ID)
/
-----------------------------------------------------------------------------
-- PDP_PMT_GRP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PDP_PMT_GRP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PDP_PMT_GRP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PDP_PMT_GRP_T
(
PMT_GRP_ID NUMBER(8)
, OBJ_ID VARCHAR2(36)
, VER_NBR NUMBER(8) default 1 NOT NULL
, PMT_PAYEE_NM VARCHAR2(123)
, DISB_NBR NUMBER(9)
, PAYEE_ID VARCHAR2(25)
, DISB_TS DATE
, PAYEE_ID_TYP_CD VARCHAR2(1)
, PHYS_CMP_PROC_CD VARCHAR2(2)
, PMT_SORT_ORD_VAL VARCHAR2(150)
, ALTRNT_PAYEE_ID VARCHAR2(25)
, ALTRNT_PAYEE_ID_TYP_CD VARCHAR2(1)
, PMT_ACH_EXTRT_TS DATE
, PAYEE_OWNR_CD VARCHAR2(2)
, CUST_INST_NBR VARCHAR2(30)
, PMT_LN1_ADDR VARCHAR2(55)
, PMT_LN2_ADDR VARCHAR2(55)
, PMT_LN3_ADDR VARCHAR2(55)
, PMT_LN4_ADDR VARCHAR2(55)
, PMT_CTY_NM VARCHAR2(50)
, PMT_ZIP_CD VARCHAR2(20)
, PMT_ST_NM VARCHAR2(30)
, CMP_ADDR_IND VARCHAR2(1)
, PMT_DT DATE
, PMT_CNTRY_NM VARCHAR2(30)
, PMT_ATTCHMNT_IND VARCHAR2(1)
, PMT_SPCL_HANDLG_IND VARCHAR2(1)
, PMT_TXBL_IND VARCHAR2(1)
, NRA_PMT_IND VARCHAR2(1)
, PROC_IMD_IND VARCHAR2(1)
, CUST_ACCT_TYP_CD VARCHAR2(2)
, ACH_BNK_RTNG_NBR VARCHAR2(9)
, ADV_EMAIL_ADDR VARCHAR2(200)
, EMP_IND VARCHAR2(1)
, PMT_FIL_ID NUMBER(8)
, DISB_TYP_CD VARCHAR2(4)
, PMT_STAT_CD VARCHAR2(4)
, LST_UPDT_TS DATE NOT NULL
, PROC_ID NUMBER(8)
, PMT_GRP_CMB_IND VARCHAR2(1) NOT NULL
, ADV_EMAIL_SNT_TS DATE
, PDP_EPIC_PMT_CNCL_EXTRT_TS DATE
, PDP_EPIC_PMT_PD_EXTRT_TS DATE
, BNK_CD VARCHAR2(4)
, VNDR_ALIAS_NM VARCHAR2(45)
)
/
ALTER TABLE PDP_PMT_GRP_T
ADD CONSTRAINT PDP_PMT_GRP_TP1
PRIMARY KEY (PMT_GRP_ID)
/
CREATE INDEX PDP_PMT_GRP_TI2
ON PDP_PMT_GRP_T
(PMT_FIL_ID)
/
CREATE INDEX PDP_PMT_GRP_TI4
ON PDP_PMT_GRP_T
(DISB_TYP_CD)
/
CREATE INDEX PDP_PMT_GRP_TI5
ON PDP_PMT_GRP_T
(PMT_STAT_CD)
/
CREATE INDEX PDP_PMT_GRP_TI6
ON PDP_PMT_GRP_T
(DISB_NBR)
/
CREATE INDEX PDP_PMT_GRP_TI7
ON PDP_PMT_GRP_T
(PMT_PAYEE_NM)
/
CREATE INDEX PDP_PMT_GRP_TI8
ON PDP_PMT_GRP_T
(PROC_ID)
/
-----------------------------------------------------------------------------
-- PDP_PMT_NTE_TXT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PDP_PMT_NTE_TXT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PDP_PMT_NTE_TXT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PDP_PMT_NTE_TXT_T
(
PMT_NTE_ID NUMBER(8)
, OBJ_ID VARCHAR2(36)
, VER_NBR NUMBER(8) default 1 NOT NULL
, CUST_NTE_LN_NBR NUMBER(2) NOT NULL
, CUST_NTE_TXT VARCHAR2(90) NOT NULL
, PMT_DTL_ID NUMBER(8)
, LST_UPDT_TS DATE NOT NULL
, CONSTRAINT PDP_PMT_NTE_TXT_TC1 UNIQUE (PMT_DTL_ID, CUST_NTE_LN_NBR)
)
/
ALTER TABLE PDP_PMT_NTE_TXT_T
ADD CONSTRAINT PDP_PMT_NTE_TXT_TP1
PRIMARY KEY (PMT_NTE_ID)
/
CREATE INDEX PDP_PMT_NTE_TXT_TI3
ON PDP_PMT_NTE_TXT_T
(PMT_DTL_ID)
/
-----------------------------------------------------------------------------
-- PDP_PMT_STAT_CD_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PDP_PMT_STAT_CD_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PDP_PMT_STAT_CD_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PDP_PMT_STAT_CD_T
(
PMT_STAT_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36)
, VER_NBR NUMBER(8) default 1 NOT NULL
, PMT_STAT_CD_DESC VARCHAR2(25) NOT NULL
)
/
ALTER TABLE PDP_PMT_STAT_CD_T
ADD CONSTRAINT PDP_PMT_STAT_CD_TP1
PRIMARY KEY (PMT_STAT_CD)
/
-----------------------------------------------------------------------------
-- PDP_PMT_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PDP_PMT_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PDP_PMT_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PDP_PMT_TYP_T
(
PMT_TYP_CD VARCHAR2(100)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, PMT_TYP_DESC VARCHAR2(200) NOT NULL
, CONSTRAINT PDP_PMT_TYP_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PDP_PMT_TYP_T
ADD CONSTRAINT PDP_PMT_TYP_TP1
PRIMARY KEY (PMT_TYP_CD)
/
-----------------------------------------------------------------------------
-- PDP_PROC_SUM_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PDP_PROC_SUM_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PDP_PROC_SUM_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PDP_PROC_SUM_T
(
PROC_SUM_ID NUMBER(8)
, OBJ_ID VARCHAR2(36)
, VER_NBR NUMBER(8) default 1 NOT NULL
, DISB_TYP_CD VARCHAR2(4) NOT NULL
, PMT_SORT_ORD_VAL NUMBER(22) NOT NULL
, BEG_DISB_NBR NUMBER(9) NOT NULL
, END_DISB_NBR NUMBER(9) NOT NULL
, PROC_TOT_AMT NUMBER(19,2) NOT NULL
, PROC_TOT_CNT NUMBER(6) NOT NULL
, CUST_ID NUMBER(8) NOT NULL
, PROC_ID NUMBER(8)
, LST_UPDT_TS DATE NOT NULL
)
/
ALTER TABLE PDP_PROC_SUM_T
ADD CONSTRAINT PDP_PROC_SUM_TP1
PRIMARY KEY (PROC_SUM_ID)
/
CREATE INDEX PDP_PROC_SUM_TI2
ON PDP_PROC_SUM_T
(DISB_TYP_CD)
/
CREATE INDEX PDP_PROC_SUM_TI3
ON PDP_PROC_SUM_T
(CUST_ID)
/
CREATE INDEX PDP_PROC_SUM_TI4
ON PDP_PROC_SUM_T
(PROC_ID)
/
-----------------------------------------------------------------------------
-- PDP_PROC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PDP_PROC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PDP_PROC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PDP_PROC_T
(
PROC_ID NUMBER(8)
, OBJ_ID VARCHAR2(36)
, VER_NBR NUMBER(8) default 1 NOT NULL
, PHYS_CMP_CD VARCHAR2(2) NOT NULL
, PROC_TS DATE NOT NULL
, EXTR_TS DATE
, PROC_USR_ID VARCHAR2(40) NOT NULL
, LST_UPDT_TS DATE NOT NULL
, EXTRACTED_IND VARCHAR2(1) default 'Y'
, FORMATTED_IND VARCHAR2(1) default 'N'
)
/
ALTER TABLE PDP_PROC_T
ADD CONSTRAINT PDP_PROC_TP1
PRIMARY KEY (PROC_ID)
/
-----------------------------------------------------------------------------
-- PUR_ADDR_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_ADDR_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_ADDR_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_ADDR_TYP_T
(
VNDR_ADDR_TYP_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, VNDR_ADDR_TYP_DESC VARCHAR2(45)
, VNDR_DFLT_IND VARCHAR2(1)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT PUR_ADDR_TYP_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_ADDR_TYP_T
ADD CONSTRAINT PUR_ADDR_TYP_TP1
PRIMARY KEY (VNDR_ADDR_TYP_CD)
/
-----------------------------------------------------------------------------
-- PUR_AP_CMP_PARM_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_AP_CMP_PARM_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_AP_CMP_PARM_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_AP_CMP_PARM_T
(
CAMPUS_CD VARCHAR2(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CMP_PUR_DRCTR_NM VARCHAR2(45)
, CMP_PUR_DRCTR_TTL VARCHAR2(45)
, CMP_AP_EMAIL_ADDR VARCHAR2(100)
, PUR_INST_NM VARCHAR2(45)
, PUR_DEPT_NM VARCHAR2(45)
, PUR_DEPT_LN1_ADDR VARCHAR2(45)
, PUR_DEPT_LN2_ADDR VARCHAR2(45)
, PUR_DEPT_CTY_NM VARCHAR2(45)
, PUR_DEPT_ST_CD VARCHAR2(2)
, PUR_DEPT_ZIP_CD VARCHAR2(20)
, PUR_DEPT_CNTRY_CD VARCHAR2(2)
, ACTV_IND VARCHAR2(1) default 'Y'
, CONSTRAINT PUR_AP_CMP_PARM_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_AP_CMP_PARM_T
ADD CONSTRAINT PUR_AP_CMP_PARM_TP1
PRIMARY KEY (CAMPUS_CD)
/
CREATE INDEX PUR_AP_CMP_PARM_TI1
ON PUR_AP_CMP_PARM_T
(CMP_PUR_DRCTR_NM)
/
-----------------------------------------------------------------------------
-- PUR_AP_ITM_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_AP_ITM_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_AP_ITM_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_AP_ITM_TYP_T
(
ITM_TYP_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ITM_TYP_DESC VARCHAR2(45) NOT NULL
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, QTY_BSD_GL_IND VARCHAR2(1) NOT NULL
, ITM_TYP_ADDL_CHRG_IND VARCHAR2(1) NOT NULL
, TAXABLE_IND VARCHAR2(1) default 'Y' NOT NULL
, CONSTRAINT PUR_AP_ITM_TYP_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_AP_ITM_TYP_T
ADD CONSTRAINT PUR_AP_ITM_TYP_TP1
PRIMARY KEY (ITM_TYP_CD)
/
-----------------------------------------------------------------------------
-- PUR_AP_ORG_PARM_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_AP_ORG_PARM_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_AP_ORG_PARM_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_AP_ORG_PARM_T
(
FIN_COA_CD VARCHAR2(2)
, ORG_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ORG_AUTO_PO_LMT NUMBER(19,2)
, ACTV_IND VARCHAR2(1) default 'Y'
, CONSTRAINT PUR_AP_ORG_PARM_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_AP_ORG_PARM_T
ADD CONSTRAINT PUR_AP_ORG_PARM_TP1
PRIMARY KEY (FIN_COA_CD,ORG_CD)
/
-----------------------------------------------------------------------------
-- PUR_AP_RECUR_PMT_FREQ_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_AP_RECUR_PMT_FREQ_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_AP_RECUR_PMT_FREQ_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_AP_RECUR_PMT_FREQ_T
(
RECUR_PMT_FREQ_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, RECUR_PMT_FREQ_DESC VARCHAR2(45)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT PUR_AP_RECUR_PMT_FREQ_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_AP_RECUR_PMT_FREQ_T
ADD CONSTRAINT PUR_AP_RECUR_PMT_FREQ_TP1
PRIMARY KEY (RECUR_PMT_FREQ_CD)
/
-----------------------------------------------------------------------------
-- PUR_AP_RECUR_PMT_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_AP_RECUR_PMT_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_AP_RECUR_PMT_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_AP_RECUR_PMT_TYP_T
(
RECUR_PMT_TYP_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, RECUR_PMT_TYP_DESC VARCHAR2(45) NOT NULL
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT PUR_AP_RECUR_PMT_TYP_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_AP_RECUR_PMT_TYP_T
ADD CONSTRAINT PUR_AP_RECUR_PMT_TYP_TP1
PRIMARY KEY (RECUR_PMT_TYP_CD)
/
-----------------------------------------------------------------------------
-- PUR_ASGN_CONTR_MGR_DTL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_ASGN_CONTR_MGR_DTL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_ASGN_CONTR_MGR_DTL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_ASGN_CONTR_MGR_DTL_T
(
FDOC_NBR VARCHAR2(14)
, REQS_ID NUMBER(8)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CONTR_MGR_CD NUMBER(2)
, CONSTRAINT PUR_ASGN_CONTR_MGR_DTL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_ASGN_CONTR_MGR_DTL_T
ADD CONSTRAINT PUR_ASGN_CONTR_MGR_DTL_TP1
PRIMARY KEY (FDOC_NBR,REQS_ID)
/
-----------------------------------------------------------------------------
-- PUR_ASGN_CONTR_MGR_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_ASGN_CONTR_MGR_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_ASGN_CONTR_MGR_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_ASGN_CONTR_MGR_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CONSTRAINT PUR_ASGN_CONTR_MGR_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_ASGN_CONTR_MGR_T
ADD CONSTRAINT PUR_ASGN_CONTR_MGR_TP1
PRIMARY KEY (FDOC_NBR)
/
-----------------------------------------------------------------------------
-- PUR_BILL_ADDR_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_BILL_ADDR_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_BILL_ADDR_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_BILL_ADDR_T
(
BILL_CMP_CD VARCHAR2(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, BILL_NM VARCHAR2(45) NOT NULL
, BILL_LN1_ADDR VARCHAR2(45) NOT NULL
, BILL_LN2_ADDR VARCHAR2(45)
, BILL_CTY_NM VARCHAR2(45) NOT NULL
, BILL_ST_CD VARCHAR2(2) NOT NULL
, BILL_PSTL_CD VARCHAR2(20) NOT NULL
, BILL_CNTRY_CD VARCHAR2(2) NOT NULL
, BILL_PHN_NBR VARCHAR2(45)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, BILL_EMAIL_ADDR VARCHAR2(100)
, CONSTRAINT PUR_BILL_ADDR_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_BILL_ADDR_T
ADD CONSTRAINT PUR_BILL_ADDR_TP1
PRIMARY KEY (BILL_CMP_CD)
/
-----------------------------------------------------------------------------
-- PUR_BLK_RCVNG_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_BLK_RCVNG_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_BLK_RCVNG_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_BLK_RCVNG_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, PO_ID NUMBER(9)
, CARI_CD VARCHAR2(4)
, SHPMNT_PKNG_SLP_NBR VARCHAR2(45)
, SHPMNT_BLL_OF_LDNG_NBR VARCHAR2(45)
, TRAKNG_NBR VARCHAR2(45)
, SHPMNT_RCVD_DT DATE NOT NULL
, SHPMNT_REF_NBR VARCHAR2(45)
, SHPMNT_WGHT VARCHAR2(45)
, CRTNS_CNT NUMBER(10)
, RQSTR_PRSN_NM VARCHAR2(80)
, RQSTR_PRSN_PHN_NBR VARCHAR2(12)
, RQSTR_PRSN_EMAIL_ADDR VARCHAR2(100)
, PREPR_PRSN_NM VARCHAR2(123)
, PREPR_PRSN_PHN_NBR VARCHAR2(12)
, VNDR_HDR_GNRTD_ID NUMBER(10)
, VNDR_DTL_ASND_ID NUMBER(10)
, VNDR_NM VARCHAR2(45)
, VNDR_LN1_ADDR VARCHAR2(45)
, VNDR_LN2_ADDR VARCHAR2(45)
, VNDR_CTY_NM VARCHAR2(45)
, VNDR_ST_CD VARCHAR2(2)
, VNDR_PSTL_CD VARCHAR2(20)
, VNDR_CNTRY_CD VARCHAR2(2)
, VNDR_ADDR_INTL_PROV_NM VARCHAR2(45)
, VNDR_NTE_TXT VARCHAR2(255)
, ALTRNT_VNDR_HDR_GNRTD_ID NUMBER(10)
, ALTRNT_VNDR_DTL_ASND_ID NUMBER(10)
, GDS_DLVD_VNDR_HDR_GNRTD_ID NUMBER(10)
, GDS_DLVD_VNDR_DTL_ASND_ID NUMBER(10)
, DLVY_BLDG_CD VARCHAR2(10)
, DLVY_BLDG_NM VARCHAR2(45)
, DLVY_BLDG_RM_NBR VARCHAR2(8)
, DLVY_BLDG_LN1_ADDR VARCHAR2(45)
, DLVY_BLDG_LN2_ADDR VARCHAR2(45)
, DLVY_CTY_NM VARCHAR2(45)
, DLVY_ST_CD VARCHAR2(2)
, DLVY_PSTL_CD VARCHAR2(20)
, DLVY_CNTRY_CD VARCHAR2(2)
, DLVY_TO_NM VARCHAR2(45)
, DLVY_TO_EMAIL_ADDR VARCHAR2(100)
, DLVY_TO_PHN_NBR VARCHAR2(45)
, DLVY_CMP_CD VARCHAR2(2)
, DLVY_INSTRC_TXT VARCHAR2(255)
, DLVY_ADDL_INSTRC_TXT VARCHAR2(255)
, INST_CNTCT_NM VARCHAR2(45)
, INST_CNTCT_PHN_NBR VARCHAR2(45)
, INST_CNTCT_EMAIL_ADDR VARCHAR2(100)
, AP_PUR_DOC_LNK_ID NUMBER(10)
, DLVY_BLDG_OTHR_IND VARCHAR2(1)
)
/
ALTER TABLE PUR_BLK_RCVNG_T
ADD CONSTRAINT PUR_BLK_RCVNG_TP1
PRIMARY KEY (FDOC_NBR)
/
CREATE INDEX PUR_BLK_RCVNG_TI1
ON PUR_BLK_RCVNG_T
(AP_PUR_DOC_LNK_ID)
/
-----------------------------------------------------------------------------
-- PUR_CARI_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_CARI_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_CARI_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_CARI_T
(
CARI_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CARI_DESC VARCHAR2(45) NOT NULL
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT PUR_CARI_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_CARI_T
ADD CONSTRAINT PUR_CARI_TP1
PRIMARY KEY (CARI_CD)
/
-----------------------------------------------------------------------------
-- PUR_CNTCT_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_CNTCT_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_CNTCT_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_CNTCT_TYP_T
(
VNDR_CNTCT_TYP_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, VNDR_CNTCT_TYP_DESC VARCHAR2(45)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT PUR_CNTCT_TYP_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_CNTCT_TYP_T
ADD CONSTRAINT PUR_CNTCT_TYP_TP1
PRIMARY KEY (VNDR_CNTCT_TYP_CD)
/
-----------------------------------------------------------------------------
-- PUR_COMM_CONTR_MGR_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_COMM_CONTR_MGR_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_COMM_CONTR_MGR_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_COMM_CONTR_MGR_T
(
PUR_COMM_CD VARCHAR2(40)
, CAMPUS_CD VARCHAR2(2)
, CONTR_MGR_CD NUMBER(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CONTR_MGR_ACTV_IND VARCHAR2(1)
, CONSTRAINT PUR_COMM_CONTR_MGR_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_COMM_CONTR_MGR_T
ADD CONSTRAINT PUR_COMM_CONTR_MGR_TP1
PRIMARY KEY (PUR_COMM_CD,CAMPUS_CD,CONTR_MGR_CD)
/
-----------------------------------------------------------------------------
-- PUR_COMM_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_COMM_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_COMM_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_COMM_T
(
PUR_COMM_CD VARCHAR2(40)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, PUR_COMM_DESC VARCHAR2(200) NOT NULL
, PUR_SALES_TAX_IND VARCHAR2(1)
, ITM_RSTRC_IND VARCHAR2(1)
, SNSTV_DTA_CD VARCHAR2(4)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT PUR_COMM_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_COMM_T
ADD CONSTRAINT PUR_COMM_TP1
PRIMARY KEY (PUR_COMM_CD)
/
-----------------------------------------------------------------------------
-- PUR_CONTR_MGR_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_CONTR_MGR_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_CONTR_MGR_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_CONTR_MGR_T
(
CONTR_MGR_CD NUMBER(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CONTR_MGR_NM VARCHAR2(45) NOT NULL
, CONTR_MGR_PHN_NBR VARCHAR2(45) NOT NULL
, CONTR_MGR_FAX_NBR VARCHAR2(45) NOT NULL
, CONTR_MGR_DLGN_DLR_LMT NUMBER(19,2)
, ACTV_IND VARCHAR2(1) default 'Y'
, CONSTRAINT PUR_CONTR_MGR_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_CONTR_MGR_T
ADD CONSTRAINT PUR_CONTR_MGR_TP1
PRIMARY KEY (CONTR_MGR_CD)
/
-----------------------------------------------------------------------------
-- PUR_CPTL_AST_SYS_ST_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_CPTL_AST_SYS_ST_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_CPTL_AST_SYS_ST_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_CPTL_AST_SYS_ST_T
(
CPTL_AST_SYS_ST_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CPTL_AST_SYS_ST_DESC VARCHAR2(45)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1)
, CONSTRAINT PUR_CPTL_AST_SYS_ST_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_CPTL_AST_SYS_ST_T
ADD CONSTRAINT PUR_CPTL_AST_SYS_ST_TP1
PRIMARY KEY (CPTL_AST_SYS_ST_CD)
/
-----------------------------------------------------------------------------
-- PUR_CPTL_AST_SYS_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_CPTL_AST_SYS_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_CPTL_AST_SYS_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_CPTL_AST_SYS_TYP_T
(
CPTL_AST_SYS_TYP_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CPTL_AST_SYS_TYP_DESC VARCHAR2(45)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT PUR_CPTL_AST_SYS_TYP_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_CPTL_AST_SYS_TYP_T
ADD CONSTRAINT PUR_CPTL_AST_SYS_TYP_TP1
PRIMARY KEY (CPTL_AST_SYS_TYP_CD)
/
-----------------------------------------------------------------------------
-- PUR_DFLT_PRNCPL_ADDR_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_DFLT_PRNCPL_ADDR_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_DFLT_PRNCPL_ADDR_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_DFLT_PRNCPL_ADDR_T
(
PRNCPL_ID VARCHAR2(40)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CAMPUS_CD VARCHAR2(2)
, BLDG_CD VARCHAR2(10)
, BLDG_ROOM_NBR VARCHAR2(8)
, CONSTRAINT PUR_DFLT_PRNCPL_ADDR_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_DFLT_PRNCPL_ADDR_T
ADD CONSTRAINT PUR_DFLT_PRNCPL_ADDR_TP1
PRIMARY KEY (PRNCPL_ID)
/
-----------------------------------------------------------------------------
-- PUR_DLVY_REQ_DT_REAS_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_DLVY_REQ_DT_REAS_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_DLVY_REQ_DT_REAS_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_DLVY_REQ_DT_REAS_T
(
DLVY_REQ_DT_REAS_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, DLVY_REQ_DT_REAS_DESC VARCHAR2(45) NOT NULL
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT PUR_DLVY_REQ_DT_REAS_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_DLVY_REQ_DT_REAS_T
ADD CONSTRAINT PUR_DLVY_REQ_DT_REAS_TP1
PRIMARY KEY (DLVY_REQ_DT_REAS_CD)
/
-----------------------------------------------------------------------------
-- PUR_FND_SRC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_FND_SRC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_FND_SRC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_FND_SRC_T
(
FND_SRC_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FND_SRC_DESC VARCHAR2(45) NOT NULL
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT PUR_FND_SRC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_FND_SRC_T
ADD CONSTRAINT PUR_FND_SRC_TP1
PRIMARY KEY (FND_SRC_CD)
/
-----------------------------------------------------------------------------
-- PUR_ITM_REAS_ADD_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_ITM_REAS_ADD_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_ITM_REAS_ADD_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_ITM_REAS_ADD_T
(
ITM_REAS_ADD_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ITM_REAS_ADD_DESC VARCHAR2(45)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT PUR_ITM_REAS_ADD_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_ITM_REAS_ADD_T
ADD CONSTRAINT PUR_ITM_REAS_ADD_TP1
PRIMARY KEY (ITM_REAS_ADD_CD)
/
-----------------------------------------------------------------------------
-- PUR_OWNR_CTGRY_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_OWNR_CTGRY_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_OWNR_CTGRY_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_OWNR_CTGRY_T
(
VNDR_OWNR_CTGRY_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, VNDR_OWNR_CTGRY_DESC VARCHAR2(45)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT PUR_OWNR_CTGRY_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_OWNR_CTGRY_T
ADD CONSTRAINT PUR_OWNR_CTGRY_TP1
PRIMARY KEY (VNDR_OWNR_CTGRY_CD)
/
-----------------------------------------------------------------------------
-- PUR_OWNR_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_OWNR_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_OWNR_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_OWNR_TYP_T
(
VNDR_OWNR_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, VNDR_OWNR_DESC VARCHAR2(45)
, VNDR_OWNR_CTGRY_ALLW_IND VARCHAR2(1)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT PUR_OWNR_TYP_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_OWNR_TYP_T
ADD CONSTRAINT PUR_OWNR_TYP_TP1
PRIMARY KEY (VNDR_OWNR_CD)
/
-----------------------------------------------------------------------------
-- PUR_PHN_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_PHN_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_PHN_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_PHN_TYP_T
(
VNDR_PHN_TYP_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, VNDR_PHN_TYP_DESC VARCHAR2(45)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT PUR_PHN_TYP_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_PHN_TYP_T
ADD CONSTRAINT PUR_PHN_TYP_TP1
PRIMARY KEY (VNDR_PHN_TYP_CD)
/
-----------------------------------------------------------------------------
-- PUR_PMT_TERM_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_PMT_TERM_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_PMT_TERM_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_PMT_TERM_TYP_T
(
VNDR_PMT_TERM_CD VARCHAR2(5)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, VNDR_DSCT_DUE_TYP_DESC VARCHAR2(20)
, VNDR_DSCT_DUE_NBR NUMBER(2)
, VNDR_PMT_TERM_PCT NUMBER(6,3)
, VNDR_NET_DUE_TYP_DESC VARCHAR2(20)
, VNDR_NET_DUE_NBR NUMBER(2)
, VNDR_PMT_TERM_DESC VARCHAR2(45)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT PUR_PMT_TERM_TYP_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_PMT_TERM_TYP_T
ADD CONSTRAINT PUR_PMT_TERM_TYP_TP1
PRIMARY KEY (VNDR_PMT_TERM_CD)
/
-----------------------------------------------------------------------------
-- PUR_PO_ACCT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_PO_ACCT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_PO_ACCT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_PO_ACCT_T
(
FDOC_NBR VARCHAR2(14)
, PO_ACCT_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, PO_ITM_ID NUMBER(10)
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_OBJECT_CD VARCHAR2(4)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, PROJECT_CD VARCHAR2(10)
, ORG_REFERENCE_ID VARCHAR2(8)
, ACLN_PCT NUMBER(35,20) default 100
, ITM_ACCT_OSTND_ENCUM_AMT NUMBER(19,2)
, ACLN_AMT NUMBER(19,2)
, FDOC_LINE_NBR NUMBER(7)
, CONSTRAINT PUR_PO_ACCT_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_PO_ACCT_T
ADD CONSTRAINT PUR_PO_ACCT_TP1
PRIMARY KEY (FDOC_NBR,PO_ACCT_ID)
/
-----------------------------------------------------------------------------
-- PUR_PO_CONTR_LANG_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_PO_CONTR_LANG_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_PO_CONTR_LANG_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_PO_CONTR_LANG_T
(
PO_CONTR_LANG_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CMP_CD VARCHAR2(2) NOT NULL
, PO_CONTR_LANG_DESC VARCHAR2(2000) NOT NULL
, CONTR_LANG_CRTE_DT DATE NOT NULL
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT PUR_PO_CONTR_LANG_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_PO_CONTR_LANG_T
ADD CONSTRAINT PUR_PO_CONTR_LANG_TP1
PRIMARY KEY (PO_CONTR_LANG_ID)
/
-----------------------------------------------------------------------------
-- PUR_PO_CPTL_AST_ITM_AST_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_PO_CPTL_AST_ITM_AST_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_PO_CPTL_AST_ITM_AST_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_PO_CPTL_AST_ITM_AST_T
(
PO_ITM_CPTL_AST_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CPTLAST_NBR NUMBER(12)
, CPTL_AST_SYS_ID NUMBER(10)
, CONSTRAINT PUR_PO_CPTL_AST_ITM_AST_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_PO_CPTL_AST_ITM_AST_T
ADD CONSTRAINT PUR_PO_CPTL_AST_ITM_AST_TP1
PRIMARY KEY (PO_ITM_CPTL_AST_ID)
/
-----------------------------------------------------------------------------
-- PUR_PO_CPTL_AST_ITM_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_PO_CPTL_AST_ITM_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_PO_CPTL_AST_ITM_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_PO_CPTL_AST_ITM_T
(
CPTL_AST_ITM_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_NBR VARCHAR2(14)
, PO_ITM_ID NUMBER(10)
, CPTL_AST_TRN_TYP_CD VARCHAR2(4)
, CPTL_AST_SYS_ID NUMBER(10)
, CONSTRAINT PUR_PO_CPTL_AST_ITM_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_PO_CPTL_AST_ITM_T
ADD CONSTRAINT PUR_PO_CPTL_AST_ITM_TP1
PRIMARY KEY (CPTL_AST_ITM_ID)
/
-----------------------------------------------------------------------------
-- PUR_PO_CPTL_AST_LOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_PO_CPTL_AST_LOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_PO_CPTL_AST_LOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_PO_CPTL_AST_LOC_T
(
CPTL_AST_LOC_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CPTL_AST_SYS_ID NUMBER(10)
, CPTL_AST_ITM_QTY NUMBER(11,2)
, CAMPUS_CD VARCHAR2(2)
, CPTL_AST_OFF_CMP_IND VARCHAR2(1)
, BLDG_CD VARCHAR2(10)
, BLDG_ROOM_NBR VARCHAR2(8)
, CPTL_AST_LN1_ADDR VARCHAR2(45)
, CPTL_AST_CTY_NM VARCHAR2(45)
, CPTL_AST_ST_CD VARCHAR2(2)
, CPTL_AST_PSTL_CD VARCHAR2(20)
, CPTL_AST_CNTRY_CD VARCHAR2(2)
, CONSTRAINT PUR_PO_CPTL_AST_LOC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_PO_CPTL_AST_LOC_T
ADD CONSTRAINT PUR_PO_CPTL_AST_LOC_TP1
PRIMARY KEY (CPTL_AST_LOC_ID)
/
-----------------------------------------------------------------------------
-- PUR_PO_CPTL_AST_SYS_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_PO_CPTL_AST_SYS_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_PO_CPTL_AST_SYS_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_PO_CPTL_AST_SYS_T
(
CPTL_AST_SYS_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_NBR VARCHAR2(14)
, CPTL_AST_SYS_DESC VARCHAR2(4000)
, CPTLAST_NOTRCVD_CUR_FSCLYR_IND VARCHAR2(1)
, CPTLAST_TYP_CD VARCHAR2(7)
, CPTL_AST_MFR_NM VARCHAR2(45)
, CPTL_AST_MDL_DESC VARCHAR2(45)
, CPTL_AST_NTE_TXT VARCHAR2(800)
, CPTL_AST_CNT_AST_NBR NUMBER(11)
, CONSTRAINT PUR_PO_CPTL_AST_SYS_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_PO_CPTL_AST_SYS_T
ADD CONSTRAINT PUR_PO_CPTL_AST_SYS_TP1
PRIMARY KEY (CPTL_AST_SYS_ID)
/
-----------------------------------------------------------------------------
-- PUR_PO_CST_SRC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_PO_CST_SRC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_PO_CST_SRC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_PO_CST_SRC_T
(
PO_CST_SRC_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, PO_CST_SRC_DESC VARCHAR2(45)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, ITM_UNIT_PRC_UPR_VAR_PCT NUMBER(3)
, ITM_UNIT_PRC_LWR_VAR_PCT NUMBER(3)
, CONSTRAINT PUR_PO_CST_SRC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_PO_CST_SRC_T
ADD CONSTRAINT PUR_PO_CST_SRC_TP1
PRIMARY KEY (PO_CST_SRC_CD)
/
-----------------------------------------------------------------------------
-- PUR_PO_ITM_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_PO_ITM_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_PO_ITM_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_PO_ITM_T
(
FDOC_NBR VARCHAR2(14)
, PO_ITM_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ITM_LN_NBR NUMBER(3)
, ITM_TYP_CD VARCHAR2(4)
, ITM_UOM_CD VARCHAR2(4) default 'EA'
, ITM_ORD_QTY NUMBER(11,2) default 1
, ITM_INV_TOT_QTY NUMBER(11,2)
, ITM_INV_TOT_AMT NUMBER(19,2)
, ITM_CATLG_NBR VARCHAR2(30)
, ITM_RCVD_TOT_QTY NUMBER(11,2)
, ITM_DESC VARCHAR2(4000)
, ITM_UNIT_PRC NUMBER(19,4)
, ITM_OSTND_ENC_QTY NUMBER(11,2)
, ITM_OSTND_ENC_AMT NUMBER(19,2)
, ITM_AUX_PART_ID VARCHAR2(300)
, ITM_ACTV_IND VARCHAR2(1)
, PUR_COMM_CD VARCHAR2(40)
, EXT_ORG_B2B_PROD_REF_NBR VARCHAR2(19)
, EXT_ORG_B2B_PROD_TYP_NM VARCHAR2(15)
, ITM_ASND_TO_TRADE_IN_IND VARCHAR2(1)
, ITM_DMGED_TOT_QTY NUMBER(11,2)
, ITM_TAX_AMT NUMBER(19,4)
, OLE_REQ_SRC_URL VARCHAR2(700)
, OLE_RTE_RQSTR VARCHAR2(2) default 'No'
, OLE_DOCUMENT_UUID VARCHAR2(50)
, LINK_ORD_OPT VARCHAR2(50)
, OLE_FRMT_ID NUMBER(8)
, OLE_CAT_ID NUMBER(8)
, OLE_REQ_SRC_TYP_ID NUMBER(8)
, OLE_RQSTR_TYP_ID NUMBER(8)
, PRNCPL_INT_RQSTR_ID VARCHAR2(40)
, OLE_DIS_PCT NUMBER(4,2)
, OLE_EDI_TYP_CON_ID NUMBER(10)
, OLE_VNDR_TRANS_FRMT_ID NUMBER(8)
, VNDR_HDR_GNRTD_ID NUMBER(10)
, VNDR_DTL_ASND_ID NUMBER(10)
, OLE_RQSTR_ID VARCHAR2(40)
, OLE_SCOPE_ORDER VARCHAR2(700)
, OLE_VNDR_IT_ID VARCHAR2(100)
, OLE_PO_IT_ORDR_STAT_ID NUMBER(8)
, OLE_NUM_PRTS NUMBER(11,2)
, OLE_AVL_PUB VARCHAR2(2)
, OLE_DISCNT_TYP VARCHAR2(1)
, OLE_FOR_DISCNT_TYP VARCHAR2(1)
, OLE_DISCNT NUMBER(19,4)
, OLE_FOR_DISCNT NUMBER(19,4)
, OLE_LST_PRC NUMBER(19,4)
, OLE_FOR_LST_PRC NUMBER(19,4)
, OLE_FOR_DISCNT_AMT NUMBER(19,4)
, OLE_FOR_UNT_CST NUMBER(19,4)
, OLE_EXCHANGE_RT NUMBER(19,6)
, OLE_CON_CST NUMBER(19,4)
, OLE_ITM_PRC_SRC_ID NUMBER(8)
, OLE_PO_ITM_ID NUMBER(10)
, OLE_PRTS_RCVD_TOT_QTY NUMBER(11,2)
, OLE_PRTS_DMGED_TOT_QTY NUMBER(11,2)
, OLE_REQ_RCPT_STATUS_ID NUMBER(10)
, OLE_NO_COPIES_RCVD VARCHAR2(40)
, OLE_NO_PARTS_RCVD VARCHAR2(40)
, OLE_ITM_LOC VARCHAR2(40)
, OLE_ITM_STATUS VARCHAR2(40)
, OLE_DNT_CLM VARCHAR2(2) default 'N'
, OLE_CLM_CNT NUMBER(5)
, OLE_CLM_DT DATE
, OLE_CLM_NT VARCHAR2(40)
, CONSTRAINT PUR_PO_ITM_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_PO_ITM_T
ADD CONSTRAINT PUR_PO_ITM_TP1
PRIMARY KEY (FDOC_NBR,PO_ITM_ID)
/
CREATE INDEX PUR_PO_ITM_TI3
ON PUR_PO_ITM_T
(ITM_TYP_CD)
/
CREATE INDEX PUR_PO_ITM_TI1
ON PUR_PO_ITM_T
(OLE_FRMT_ID)
/
CREATE INDEX PUR_PO_ITM_TI2
ON PUR_PO_ITM_T
(OLE_CAT_ID)
/
CREATE INDEX PUR_PO_ITM_TI4
ON PUR_PO_ITM_T
(OLE_REQ_SRC_TYP_ID)
/
CREATE INDEX PUR_PO_ITM_TI5
ON PUR_PO_ITM_T
(OLE_RQSTR_TYP_ID)
/
-----------------------------------------------------------------------------
-- PUR_PO_ITM_USE_TAX_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_PO_ITM_USE_TAX_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_PO_ITM_USE_TAX_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_PO_ITM_USE_TAX_T
(
FDOC_NBR VARCHAR2(14)
, PO_ITM_USE_TAX_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, PO_ITM_ID NUMBER(10)
, RATE_CD VARCHAR2(10) NOT NULL
, TAX_AMT NUMBER(19,4)
, FIN_COA_CD VARCHAR2(2) NOT NULL
, ACCOUNT_NBR VARCHAR2(7) NOT NULL
, FIN_OBJECT_CD VARCHAR2(4) NOT NULL
, CONSTRAINT PUR_PO_ITM_USE_TAX_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_PO_ITM_USE_TAX_T
ADD CONSTRAINT PUR_PO_ITM_USE_TAX_TP1
PRIMARY KEY (FDOC_NBR,PO_ITM_USE_TAX_ID)
/
-----------------------------------------------------------------------------
-- PUR_PO_QT_LANG_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_PO_QT_LANG_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_PO_QT_LANG_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_PO_QT_LANG_T
(
PO_QT_LANG_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, PO_QT_LANG_DESC VARCHAR2(2000)
, PO_QT_LANG_CRTE_DT DATE
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT PUR_PO_QT_LANG_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_PO_QT_LANG_T
ADD CONSTRAINT PUR_PO_QT_LANG_TP1
PRIMARY KEY (PO_QT_LANG_ID)
/
-----------------------------------------------------------------------------
-- PUR_PO_QT_LST_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_PO_QT_LST_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_PO_QT_LST_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_PO_QT_LST_T
(
PO_QT_LST_ID NUMBER(9)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, PO_QT_LST_NM VARCHAR2(100) NOT NULL
, CONTR_MGR_CD NUMBER(2) NOT NULL
, ACTV_IND VARCHAR2(1) default 'Y'
, CONSTRAINT PUR_PO_QT_LST_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_PO_QT_LST_T
ADD CONSTRAINT PUR_PO_QT_LST_TP1
PRIMARY KEY (PO_QT_LST_ID)
/
-----------------------------------------------------------------------------
-- PUR_PO_QT_LST_VNDR_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_PO_QT_LST_VNDR_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_PO_QT_LST_VNDR_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_PO_QT_LST_VNDR_T
(
PO_QT_LST_ID NUMBER(9)
, VNDR_HDR_GNRTD_ID NUMBER(10)
, VNDR_DTL_ASND_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ACTV_IND CHAR(1) default 'Y'
, CONSTRAINT PUR_PO_QT_LST_VNDR_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_PO_QT_LST_VNDR_T
ADD CONSTRAINT PUR_PO_QT_LST_VNDR_TP1
PRIMARY KEY (PO_QT_LST_ID,VNDR_HDR_GNRTD_ID,VNDR_DTL_ASND_ID)
/
CREATE INDEX PUR_PO_QT_LST_VNDR_TI1
ON PUR_PO_QT_LST_VNDR_T
(PO_QT_LST_ID)
/
-----------------------------------------------------------------------------
-- PUR_PO_QT_STAT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_PO_QT_STAT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_PO_QT_STAT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_PO_QT_STAT_T
(
PO_QT_STAT_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, PO_QT_STAT_DESC VARCHAR2(45) NOT NULL
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT PUR_PO_QT_STAT_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_PO_QT_STAT_T
ADD CONSTRAINT PUR_PO_QT_STAT_TP1
PRIMARY KEY (PO_QT_STAT_CD)
/
-----------------------------------------------------------------------------
-- PUR_PO_SNSTV_DTA_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_PO_SNSTV_DTA_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_PO_SNSTV_DTA_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_PO_SNSTV_DTA_T
(
PO_ID NUMBER(9)
, SNSTV_DTA_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, REQS_ID NUMBER(8) NOT NULL
, CONSTRAINT PUR_PO_SNSTV_DTA_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_PO_SNSTV_DTA_T
ADD CONSTRAINT PUR_PO_SNSTV_DTA_TP1
PRIMARY KEY (PO_ID,SNSTV_DTA_CD)
/
-----------------------------------------------------------------------------
-- PUR_PO_STAT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_PO_STAT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_PO_STAT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_PO_STAT_T
(
PO_STAT_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, PO_STAT_DESC VARCHAR2(45) NOT NULL
, CONSTRAINT PUR_PO_STAT_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_PO_STAT_T
ADD CONSTRAINT PUR_PO_STAT_TP1
PRIMARY KEY (PO_STAT_CD)
/
-----------------------------------------------------------------------------
-- PUR_PO_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_PO_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_PO_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_PO_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, PO_ID NUMBER(9)
, REQS_ID NUMBER(8)
, REQS_SRC_CD VARCHAR2(4)
, PO_VNDR_CHC_CD VARCHAR2(4)
, VNDR_HDR_GNRTD_ID NUMBER(10)
, VNDR_DTL_ASND_ID NUMBER(10)
, VNDR_NM VARCHAR2(45)
, VNDR_LN1_ADDR VARCHAR2(45)
, VNDR_LN2_ADDR VARCHAR2(45)
, VNDR_CTY_NM VARCHAR2(45)
, VNDR_ST_CD VARCHAR2(2)
, VNDR_PSTL_CD VARCHAR2(20)
, VNDR_CNTRY_CD VARCHAR2(2)
, VNDR_RSTRC_IND VARCHAR2(1)
, VNDR_PMT_TERM_CD VARCHAR2(5)
, VNDR_SHP_TTL_CD VARCHAR2(4)
, VNDR_PHN_NBR VARCHAR2(45)
, VNDR_FAX_NBR VARCHAR2(40)
, VNDR_CUST_NBR VARCHAR2(30)
, VNDR_CONTR_GNRTD_ID NUMBER(10)
, VNDR_NTE_TXT VARCHAR2(255)
, VNDR_SHP_PMT_TERM_CD VARCHAR2(4)
, FND_SRC_CD VARCHAR2(4)
, RQSTR_PRSN_NM VARCHAR2(45)
, RQSTR_PRSN_EMAIL_ADDR VARCHAR2(100)
, RQSTR_PRSN_PHN_NBR VARCHAR2(45)
, NON_INST_FND_ORG_COA_CD VARCHAR2(2)
, NON_INST_FND_ORG_CD VARCHAR2(4)
, NON_INST_FND_COA_CD VARCHAR2(2)
, NON_INST_FND_ACCT_NBR VARCHAR2(7)
, DLVY_CMP_CD VARCHAR2(2)
, DLVY_BLDG_CD VARCHAR2(10)
, DLVY_BLDG_NM VARCHAR2(45)
, DLVY_BLDG_RM_NBR VARCHAR2(8)
, DLVY_BLDG_LN1_ADDR VARCHAR2(45)
, DLVY_BLDG_LN2_ADDR VARCHAR2(45)
, DLVY_CTY_NM VARCHAR2(45)
, DLVY_ST_CD VARCHAR2(2)
, DLVY_PSTL_CD VARCHAR2(20)
, DLVY_CNTRY_CD VARCHAR2(2)
, DLVY_TO_NM VARCHAR2(45)
, DLVY_TO_EMAIL_ADDR VARCHAR2(100)
, DLVY_TO_PHN_NBR VARCHAR2(45)
, DLVY_REQ_DT DATE
, DLVY_INSTRC_TXT VARCHAR2(255)
, DLVY_REQ_DT_REAS_CD VARCHAR2(4)
, FIN_COA_CD VARCHAR2(2)
, ORG_CD VARCHAR2(4)
, PO_CRTE_DT DATE NOT NULL
, PO_ENCUM_FSCL_YR NUMBER(4)
, PO_CST_SRC_CD VARCHAR2(4)
, PO_TRNS_MTHD_CD VARCHAR2(4)
, PO_TOT_LMT NUMBER(19,2)
, PO_BEG_DT DATE
, PO_END_DT DATE
, RECUR_PMT_FREQ_CD VARCHAR2(4)
, RECUR_PMT_AMT NUMBER(19,2)
, RECUR_PMT_TYP_CD VARCHAR2(4)
, RECUR_PMT_DT DATE
, INST_CNTCT_NM VARCHAR2(45)
, INST_CNTCT_PHN_NBR VARCHAR2(45)
, INST_CNTCT_EMAIL_ADDR VARCHAR2(100)
, BILL_NM VARCHAR2(45)
, BILL_LN1_ADDR VARCHAR2(45)
, BILL_LN2_ADDR VARCHAR2(45)
, BILL_CTY_NM VARCHAR2(45)
, BILL_ST_CD VARCHAR2(2)
, BILL_PSTL_CD VARCHAR2(20)
, BILL_CNTRY_CD VARCHAR2(2)
, BILL_PHN_NBR VARCHAR2(20)
, INIT_PMT_AMT NUMBER(19,2)
, INIT_PMT_DT DATE
, FNL_PMT_AMT NUMBER(19,2)
, FNL_PMT_DT DATE
, EXT_ORG_B2B_SUPP_ID VARCHAR2(19)
, CONTR_MGR_CD NUMBER(2)
, PO_AUTO_IND VARCHAR2(1)
, PO_INIT_OPEN_DT DATE
, PO_LST_TRNS_DT DATE
, PO_QT_DUE_DT DATE
, PO_QT_TYP_CD VARCHAR2(25)
, PO_QT_VNDR_NTE_TXT VARCHAR2(255)
, PO_CNFRMD_IND VARCHAR2(1)
, PO_COMM_DESC VARCHAR2(7)
, PO_PREV_ID NUMBER(9)
, ALTRNT_VNDR_HDR_GNRTD_ID NUMBER(10)
, ALTRNT_VNDR_DTL_ASND_ID NUMBER(10)
, ALTRNT_VNDR_NM VARCHAR2(45)
, PO_CUR_IND VARCHAR2(1)
, PEND_ACTN_IND VARCHAR2(1)
, PO_1ST_TRNS_DT DATE
, AP_PUR_DOC_LNK_ID NUMBER(10)
, VNDR_ADDR_INTL_PROV_NM VARCHAR2(45)
, RCVNG_DOC_REQ_IND VARCHAR2(1)
, PMT_RQST_PSTV_APRVL_IND VARCHAR2(1)
, PO_QT_INITLZTN_DT DATE
, PO_QT_AWDED_DT DATE
, CPTL_AST_SYS_TYP_CD VARCHAR2(4)
, PUR_RCVNG_NM VARCHAR2(45)
, PUR_RCVNG_LN1_ADDR VARCHAR2(45)
, PUR_RCVNG_LN2_ADDR VARCHAR2(45)
, PUR_RCVNG_CTY_NM VARCHAR2(45)
, PUR_RCVNG_ST_CD VARCHAR2(2)
, PUR_RCVNG_PSTL_CD VARCHAR2(20)
, PUR_RCVNG_CNTRY_CD VARCHAR2(2)
, CPTL_AST_SYS_ST_CD VARCHAR2(4)
, PUR_RCVNG_ADDR_TO_VNDR_IND VARCHAR2(1)
, USE_TAX_IND VARCHAR2(1) default 'Y' NOT NULL
, DLVY_BLDG_OTHR_IND VARCHAR2(1)
, VNDR_ATTN_NM VARCHAR2(45)
, OLE_VNDR_TRANS_FRMT_ID NUMBER(8)
, OLE_PO_TYPE_ID NUMBER(8) default 1 NOT NULL
, OLE_LIB_PO_ID VARCHAR2(45)
, OLE_VNDR_PO_ID VARCHAR2(100)
, OLE_TRANS_TYP_ID NUMBER(10)
, ACCT_DISTR_MTD_IND VARCHAR2(1) default 'P' NOT NULL
, VNDR_DEBRD_REAS_TXT VARCHAR2(255)
, BILL_EMAIL_ADDR VARCHAR2(100)
, LIC_REQ_IND VARCHAR2(1) default 'N'
, LIC_RQMT_CD VARCHAR2(20)
, PRNCPL_ID VARCHAR2(40)
, CONSTRAINT PUR_PO_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_PO_T
ADD CONSTRAINT PUR_PO_TP1
PRIMARY KEY (FDOC_NBR)
/
CREATE INDEX PUR_PO_TI1
ON PUR_PO_T
(PO_VNDR_CHC_CD)
/
CREATE INDEX PUR_PO_TI10
ON PUR_PO_T
(PO_ID)
/
CREATE INDEX PUR_PO_TI11
ON PUR_PO_T
(AP_PUR_DOC_LNK_ID)
/
CREATE INDEX PUR_PO_TI2
ON PUR_PO_T
(RECUR_PMT_FREQ_CD)
/
CREATE INDEX PUR_PO_TI4
ON PUR_PO_T
(PO_TRNS_MTHD_CD)
/
CREATE INDEX PUR_PO_TI5
ON PUR_PO_T
(PO_CST_SRC_CD)
/
CREATE INDEX PUR_PO_TI6
ON PUR_PO_T
(DLVY_REQ_DT_REAS_CD)
/
CREATE INDEX PUR_PO_TI7
ON PUR_PO_T
(RECUR_PMT_TYP_CD)
/
CREATE INDEX PUR_PO_TI8
ON PUR_PO_T
(FND_SRC_CD)
/
CREATE INDEX PUR_PO_TI9
ON PUR_PO_T
(PO_INIT_OPEN_DT)
/
-----------------------------------------------------------------------------
-- PUR_PO_TRNS_MTHD_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_PO_TRNS_MTHD_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_PO_TRNS_MTHD_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_PO_TRNS_MTHD_T
(
PO_TRNS_MTHD_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, PO_TRNS_MTHD_DESC VARCHAR2(45) NOT NULL
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, DISPLAY_TO_USER_IND VARCHAR2(1) default 'Y'
, CONSTRAINT PUR_PO_TRNS_MTHD_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_PO_TRNS_MTHD_T
ADD CONSTRAINT PUR_PO_TRNS_MTHD_TP1
PRIMARY KEY (PO_TRNS_MTHD_CD)
/
-----------------------------------------------------------------------------
-- PUR_PO_VNDR_CHC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_PO_VNDR_CHC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_PO_VNDR_CHC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_PO_VNDR_CHC_T
(
PO_VNDR_CHC_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, PO_VNDR_CHC_DESC VARCHAR2(45) NOT NULL
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT PUR_PO_VNDR_CHC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_PO_VNDR_CHC_T
ADD CONSTRAINT PUR_PO_VNDR_CHC_TP1
PRIMARY KEY (PO_VNDR_CHC_CD)
/
-----------------------------------------------------------------------------
-- PUR_PO_VNDR_QT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_PO_VNDR_QT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_PO_VNDR_QT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_PO_VNDR_QT_T
(
FDOC_NBR VARCHAR2(14)
, PO_VNDR_QT_ID NUMBER(9)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, VNDR_HDR_GNRTD_ID NUMBER(10)
, VNDR_DTL_ASND_ID NUMBER(10)
, VNDR_NM VARCHAR2(45)
, VNDR_LN1_ADDR VARCHAR2(45)
, VNDR_LN2_ADDR VARCHAR2(45)
, VNDR_CTY_NM VARCHAR2(45)
, VNDR_ST_CD VARCHAR2(2)
, VNDR_PSTL_CD VARCHAR2(20)
, VNDR_PHN_NBR VARCHAR2(45)
, VNDR_FAX_NBR VARCHAR2(45)
, VNDR_EMAIL_ADDR VARCHAR2(100)
, VNDR_ATTN_NM VARCHAR2(45)
, PO_QT_TRANS_TYP_CD VARCHAR2(50)
, PO_QT_TRANS_DT DATE
, PO_QT_PRCE_EXPR_DT DATE
, PO_QT_STAT_CD VARCHAR2(4)
, PO_QT_AWD_DT DATE
, PO_QT_RANK_NBR VARCHAR2(3)
, VNDR_CNTRY_CD VARCHAR2(2)
, VNDR_ADDR_INTL_PROV_NM VARCHAR2(45)
, CONSTRAINT PUR_PO_VNDR_QT_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_PO_VNDR_QT_T
ADD CONSTRAINT PUR_PO_VNDR_QT_TP1
PRIMARY KEY (FDOC_NBR,PO_VNDR_QT_ID)
/
CREATE INDEX PUR_PO_VNDR_QT_TI2
ON PUR_PO_VNDR_QT_T
(PO_QT_STAT_CD)
/
-----------------------------------------------------------------------------
-- PUR_PO_VNDR_STPLTN_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_PO_VNDR_STPLTN_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_PO_VNDR_STPLTN_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_PO_VNDR_STPLTN_T
(
FDOC_NBR VARCHAR2(14)
, PO_VNDR_STPLTN_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, VNDR_STPLTN_DESC VARCHAR2(4000) NOT NULL
, VNDR_STPLTN_AUTH_EMP_ID VARCHAR2(40) NOT NULL
, VNDR_STPLTN_CRTE_DT DATE NOT NULL
, CONSTRAINT PUR_PO_VNDR_STPLTN_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_PO_VNDR_STPLTN_T
ADD CONSTRAINT PUR_PO_VNDR_STPLTN_TP1
PRIMARY KEY (FDOC_NBR,PO_VNDR_STPLTN_ID)
/
-----------------------------------------------------------------------------
-- PUR_RCVNG_ADDR_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_RCVNG_ADDR_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_RCVNG_ADDR_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_RCVNG_ADDR_T
(
PUR_RCVNG_ADDR_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FIN_COA_CD VARCHAR2(2) NOT NULL
, ORG_CD VARCHAR2(4)
, PUR_RCVNG_NM VARCHAR2(45)
, PUR_RCVNG_LN1_ADDR VARCHAR2(45)
, PUR_RCVNG_LN2_ADDR VARCHAR2(45)
, PUR_RCVNG_CTY_NM VARCHAR2(45)
, PUR_RCVNG_ST_CD VARCHAR2(2)
, PUR_RCVNG_PSTL_CD VARCHAR2(20)
, PUR_RCVNG_CNTRY_CD VARCHAR2(2)
, PUR_RCVNG_DFLT_ADDR_IND VARCHAR2(1)
, VNDR_ADDR_USE_RCVNG_IND VARCHAR2(1)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT PUR_RCVNG_ADDR_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_RCVNG_ADDR_T
ADD CONSTRAINT PUR_RCVNG_ADDR_TP1
PRIMARY KEY (PUR_RCVNG_ADDR_ID)
/
-----------------------------------------------------------------------------
-- PUR_RCVNG_COR_ITM_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_RCVNG_COR_ITM_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_RCVNG_COR_ITM_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_RCVNG_COR_ITM_T
(
RCVNG_COR_ITM_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_NBR VARCHAR2(14)
, PO_ID NUMBER(9)
, ITM_LN_NBR NUMBER(3)
, ITM_TYP_CD VARCHAR2(4)
, ITM_UOM_CD VARCHAR2(4)
, ITM_CATLG_NBR VARCHAR2(30)
, ITM_DESC VARCHAR2(4000)
, ITM_ORIG_RCVD_TOT_QTY NUMBER(11,2)
, ITM_ORIG_RTRN_TOT_QTY NUMBER(11,2)
, ITM_ORIG_DMGED_TOT_QTY NUMBER(11,2)
, ITM_COR_RCVD_TOT_QTY NUMBER(11,2)
, ITM_COR_RTRN_TOT_QTY NUMBER(11,2)
, ITM_COR_DMGED_TOT_QTY NUMBER(11,2)
, ITM_REAS_ADD_CD VARCHAR2(4)
, OLE_VNDR_IT_ID VARCHAR2(100)
, OLE_FRMT_ID NUMBER(8)
, OLE_ITM_ORIG_PRTS_RCVD_TOT_QTY NUMBER(11,2)
, OLE_ITM_ORIG_PRTS_RTRN_TOT_QTY NUMBER(11,2)
, OLE_ITM_ORIG_PRTS_DMGD_TOT_QTY NUMBER(11,2)
, OLE_ITM_COR_PRTS_RCVD_TOT_QTY NUMBER(11,2)
, OLE_ITM_COR_PRTS_RTRN_TOT_QTY NUMBER(11,2)
, OLE_ITM_COR_PRTS_DMGED_TOT_QTY NUMBER(11,2)
, OLE_ITM_ORIG_RCVD_DT DATE
, OLE_ITM_COR_RCVD_DT DATE
, FIN_COA_CD VARCHAR2(2)
, ORG_CD VARCHAR2(4)
, OLE_PO_ITM_ID NUMBER(10)
, CONSTRAINT PUR_RCVNG_COR_ITM_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_RCVNG_COR_ITM_T
ADD CONSTRAINT PUR_RCVNG_COR_ITM_TP1
PRIMARY KEY (RCVNG_COR_ITM_ID)
/
-----------------------------------------------------------------------------
-- PUR_RCVNG_COR_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_RCVNG_COR_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_RCVNG_COR_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_RCVNG_COR_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, RCVNG_LN_FDOC_NBR VARCHAR2(14)
, AP_PUR_DOC_LNK_ID NUMBER(10)
, CONSTRAINT PUR_RCVNG_COR_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_RCVNG_COR_T
ADD CONSTRAINT PUR_RCVNG_COR_TP1
PRIMARY KEY (FDOC_NBR)
/
CREATE INDEX PUR_RCVNG_COR_TI1
ON PUR_RCVNG_COR_T
(AP_PUR_DOC_LNK_ID)
/
-----------------------------------------------------------------------------
-- PUR_RCVNG_LN_ITM_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_RCVNG_LN_ITM_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_RCVNG_LN_ITM_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_RCVNG_LN_ITM_T
(
RCVNG_LN_ITM_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_NBR VARCHAR2(14)
, PO_ID NUMBER(9)
, ITM_LN_NBR NUMBER(3)
, ITM_TYP_CD VARCHAR2(4)
, ITM_UOM_CD VARCHAR2(4) default 'EA'
, ITM_ORD_QTY NUMBER(11,2)
, ITM_CATLG_NBR VARCHAR2(30)
, ITM_DESC VARCHAR2(4000)
, ITM_RCVD_TOT_QTY NUMBER(11,2)
, ITM_RTRN_TOT_QTY NUMBER(11,2)
, ITM_DMGED_TOT_QTY NUMBER(11,2)
, ITM_REAS_ADD_CD VARCHAR2(4)
, OLE_RTE_RQSTR VARCHAR2(2)
, OLE_NUM_PRTS NUMBER(11,2)
, OLE_ITM_PRTS_RCVD_TOT_QTY NUMBER(11,2)
, OLE_ITM_PRTS_RTND_TOT_QTY NUMBER(11,2)
, OLE_ITM_PRTS_DMGD_TOT_QTY NUMBER(11,2)
, OLE_ITM_RCVD_DT DATE default SYSDATE
, FIN_COA_CD VARCHAR2(2)
, ORG_CD VARCHAR2(4)
, OLE_VNDR_IT_ID VARCHAR2(100)
, OLE_AVL_PUB VARCHAR2(1)
, OLE_FRMT_ID NUMBER(8)
, OLE_REQ_RCPT_STATUS_ID NUMBER(10)
, CONSTRAINT PUR_RCVNG_LN_ITM_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_RCVNG_LN_ITM_T
ADD CONSTRAINT PUR_RCVNG_LN_ITM_TP1
PRIMARY KEY (RCVNG_LN_ITM_ID)
/
-----------------------------------------------------------------------------
-- PUR_RCVNG_LN_STAT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_RCVNG_LN_STAT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_RCVNG_LN_STAT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_RCVNG_LN_STAT_T
(
RCVNG_LN_STAT_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, RCVNG_LN_STAT_DESC VARCHAR2(45)
, CONSTRAINT PUR_RCVNG_LN_STAT_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_RCVNG_LN_STAT_T
ADD CONSTRAINT PUR_RCVNG_LN_STAT_TP1
PRIMARY KEY (RCVNG_LN_STAT_CD)
/
-----------------------------------------------------------------------------
-- PUR_RCVNG_LN_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_RCVNG_LN_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_RCVNG_LN_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_RCVNG_LN_T
(
FDOC_NBR VARCHAR2(14)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, PO_ID NUMBER(9)
, CARI_CD VARCHAR2(4)
, SHPMNT_PKNG_SLP_NBR VARCHAR2(45)
, SHPMNT_REF_NBR VARCHAR2(45)
, SHPMNT_BLL_OF_LDNG_NBR VARCHAR2(45)
, SHPMNT_RCVD_DT DATE
, VNDR_HDR_GNRTD_ID NUMBER(10)
, VNDR_DTL_ASND_ID NUMBER(10)
, VNDR_NM VARCHAR2(45)
, VNDR_LN1_ADDR VARCHAR2(45)
, VNDR_LN2_ADDR VARCHAR2(45)
, VNDR_CTY_NM VARCHAR2(45)
, VNDR_ST_CD VARCHAR2(2)
, VNDR_PSTL_CD VARCHAR2(20)
, VNDR_CNTRY_CD VARCHAR2(2)
, DLVY_CMP_CD VARCHAR2(2)
, DLVY_BLDG_CD VARCHAR2(10)
, DLVY_BLDG_NM VARCHAR2(45)
, DLVY_BLDG_RM_NBR VARCHAR2(8)
, DLVY_BLDG_LN1_ADDR VARCHAR2(45)
, DLVY_BLDG_LN2_ADDR VARCHAR2(45)
, DLVY_CTY_NM VARCHAR2(45)
, DLVY_ST_CD VARCHAR2(2)
, DLVY_PSTL_CD VARCHAR2(20)
, DLVY_CNTRY_CD VARCHAR2(2)
, DLVY_TO_NM VARCHAR2(45)
, DLVY_TO_EMAIL_ADDR VARCHAR2(100)
, DLVY_TO_PHN_NBR VARCHAR2(45)
, DLVY_REQ_DT DATE
, DLVY_INSTRC_TXT VARCHAR2(255)
, DLVY_REQ_DT_REAS_CD VARCHAR2(4)
, AP_PUR_DOC_LNK_ID NUMBER(10)
, DLVY_BLDG_OTHR_IND VARCHAR2(1)
, RCVNG_LN_STAT_CD VARCHAR2(4)
, OLE_VNDR_PO_ID VARCHAR2(100)
, OLE_PO_ITM_ID NUMBER(10)
, CONSTRAINT PUR_RCVNG_LN_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_RCVNG_LN_T
ADD CONSTRAINT PUR_RCVNG_LN_TP1
PRIMARY KEY (FDOC_NBR)
/
CREATE INDEX PUR_RCVNG_LN_TI1
ON PUR_RCVNG_LN_T
(AP_PUR_DOC_LNK_ID)
/
-----------------------------------------------------------------------------
-- PUR_REQS_ACCT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_REQS_ACCT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_REQS_ACCT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_REQS_ACCT_T
(
REQS_ACCT_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, REQS_ITM_ID NUMBER(10)
, FIN_COA_CD VARCHAR2(2)
, ACCOUNT_NBR VARCHAR2(7)
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_OBJECT_CD VARCHAR2(4)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, PROJECT_CD VARCHAR2(10)
, ORG_REFERENCE_ID VARCHAR2(8)
, ACLN_PCT NUMBER(35,20) default 100
, ACLN_AMT NUMBER(19,2)
, FDOC_LINE_NBR NUMBER(7)
, CONSTRAINT PUR_REQS_ACCT_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_REQS_ACCT_T
ADD CONSTRAINT PUR_REQS_ACCT_TP1
PRIMARY KEY (REQS_ACCT_ID)
/
CREATE INDEX PUR_REQS_ACCT_TI1
ON PUR_REQS_ACCT_T
(REQS_ITM_ID)
/
-----------------------------------------------------------------------------
-- PUR_REQS_CPTL_AST_ITM_AST_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_REQS_CPTL_AST_ITM_AST_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_REQS_CPTL_AST_ITM_AST_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_REQS_CPTL_AST_ITM_AST_T
(
REQS_ITM_CPTL_AST_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CPTLAST_NBR NUMBER(12) NOT NULL
, CPTL_AST_SYS_ID NUMBER(10)
, CONSTRAINT PUR_REQS_ITM_CPTL_AST_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_REQS_CPTL_AST_ITM_AST_T
ADD CONSTRAINT PUR_REQS_CPTL_AST_ITM_AST_TP1
PRIMARY KEY (REQS_ITM_CPTL_AST_ID)
/
-----------------------------------------------------------------------------
-- PUR_REQS_CPTL_AST_ITM_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_REQS_CPTL_AST_ITM_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_REQS_CPTL_AST_ITM_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_REQS_CPTL_AST_ITM_T
(
CPTL_AST_ITM_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, REQS_ID NUMBER(8)
, REQS_ITM_ID NUMBER(10)
, CPTL_AST_TRN_TYP_CD VARCHAR2(4)
, CPTL_AST_SYS_ID NUMBER(10)
, CONSTRAINT PUR_REQS_CPTL_AST_ITM_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_REQS_CPTL_AST_ITM_T
ADD CONSTRAINT PUR_REQS_CPTL_AST_ITM_TP1
PRIMARY KEY (CPTL_AST_ITM_ID)
/
CREATE INDEX PUR_REQS_CPTL_AST_ITM_TI1
ON PUR_REQS_CPTL_AST_ITM_T
(REQS_ITM_ID)
/
-----------------------------------------------------------------------------
-- PUR_REQS_CPTL_AST_LOC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_REQS_CPTL_AST_LOC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_REQS_CPTL_AST_LOC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_REQS_CPTL_AST_LOC_T
(
CPTL_AST_LOC_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CPTL_AST_SYS_ID NUMBER(10)
, CPTL_AST_ITM_QTY NUMBER(11,2)
, CAMPUS_CD VARCHAR2(2)
, CPTL_AST_OFF_CMP_IND VARCHAR2(1)
, BLDG_CD VARCHAR2(10)
, BLDG_ROOM_NBR VARCHAR2(8)
, CPTL_AST_LN1_ADDR VARCHAR2(45)
, CPTL_AST_CTY_NM VARCHAR2(45)
, CPTL_AST_ST_CD VARCHAR2(2)
, CPTL_AST_PSTL_CD VARCHAR2(20)
, CPTL_AST_CNTRY_CD VARCHAR2(2)
, CONSTRAINT PUR_REQS_CPTL_AST_LOC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_REQS_CPTL_AST_LOC_T
ADD CONSTRAINT PUR_REQS_CPTL_AST_LOC_TP1
PRIMARY KEY (CPTL_AST_LOC_ID)
/
-----------------------------------------------------------------------------
-- PUR_REQS_CPTL_AST_SYS_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_REQS_CPTL_AST_SYS_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_REQS_CPTL_AST_SYS_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_REQS_CPTL_AST_SYS_T
(
CPTL_AST_SYS_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, REQS_ID NUMBER(8)
, CPTL_AST_SYS_DESC VARCHAR2(4000)
, CPTLAST_NOTRCVD_CUR_FSCLYR_IND VARCHAR2(1)
, CPTLAST_TYP_CD VARCHAR2(7)
, CPTL_AST_MFR_NM VARCHAR2(45)
, CPTL_AST_MDL_DESC VARCHAR2(45)
, CPTL_AST_NTE_TXT VARCHAR2(800)
, CPTL_AST_CNT_AST_NBR NUMBER(11)
, CONSTRAINT PUR_REQS_CPTL_AST_SYS_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_REQS_CPTL_AST_SYS_T
ADD CONSTRAINT PUR_REQS_CPTL_AST_SYS_TP1
PRIMARY KEY (CPTL_AST_SYS_ID)
/
CREATE INDEX PUR_REQS_CPTL_AST_SYS_TI1
ON PUR_REQS_CPTL_AST_SYS_T
(REQS_ID)
/
-----------------------------------------------------------------------------
-- PUR_REQS_ITM_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_REQS_ITM_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_REQS_ITM_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_REQS_ITM_T
(
REQS_ITM_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, REQS_ID NUMBER(8) NOT NULL
, ITM_LN_NBR NUMBER(3)
, ITM_UOM_CD VARCHAR2(4) default 'EA'
, ITM_QTY NUMBER(11,2) default 1
, ITM_CATLG_NBR VARCHAR2(30)
, ITM_DESC VARCHAR2(4000)
, ITM_UNIT_PRC NUMBER(19,4)
, ITM_RSTRC_IND VARCHAR2(1) NOT NULL
, ITM_TYP_CD VARCHAR2(4)
, ITM_AUX_PART_ID VARCHAR2(300)
, EXT_ORG_B2B_PROD_REF_NBR VARCHAR2(19)
, EXT_ORG_B2B_PROD_TYP_NM VARCHAR2(15)
, ITM_ASND_TO_TRADE_IN_IND VARCHAR2(1)
, PUR_COMM_CD VARCHAR2(40)
, ITM_TAX_AMT NUMBER(19,4)
, OLE_REQ_SRC_URL VARCHAR2(700)
, OLE_RTE_RQSTR VARCHAR2(1) default 'N'
, OLE_DOCUMENT_UUID VARCHAR2(50)
, LINK_ORD_OPT VARCHAR2(50)
, OLE_FRMT_ID NUMBER(8)
, OLE_CAT_ID NUMBER(8)
, OLE_REQ_SRC_TYP_ID NUMBER(8)
, OLE_RQSTR_TYP_ID NUMBER(8)
, PRNCPL_INT_RQSTR_ID VARCHAR2(40)
, OLE_DIS_PCT NUMBER(4,2)
, OLE_SCOPE_ORDER VARCHAR2(700)
, OLE_AVL_PUB VARCHAR2(2) default 'Y' NOT NULL
, OLE_VNDR_IT_ID VARCHAR2(100)
, OLE_NUM_PRTS NUMBER(11,2)
, OLE_EDI_TYP_CON_ID NUMBER(10)
, OLE_VNDR_TRANS_FRMT_ID NUMBER(8)
, VNDR_HDR_GNRTD_ID NUMBER(10)
, VNDR_DTL_ASND_ID NUMBER(10)
, OLE_RQSTR_ID VARCHAR2(40)
, OLE_DISCNT_TYP VARCHAR2(1)
, OLE_FOR_DISCNT_TYP VARCHAR2(1)
, OLE_DISCNT NUMBER(19,4)
, OLE_FOR_DISCNT NUMBER(19,4)
, OLE_LST_PRC NUMBER(19,4)
, OLE_FOR_LST_PRC NUMBER(19,4)
, OLE_FOR_DISCNT_AMT NUMBER(19,4)
, OLE_FOR_UNT_CST NUMBER(19,4)
, OLE_EXCHANGE_RT NUMBER(19,6)
, OLE_CON_CST NUMBER(19,4)
, OLE_ITM_PRC_SRC_ID NUMBER(8)
, OLE_PO_TYPE_ID NUMBER(8) default 1
, OLE_REQ_RCPT_STATUS_ID NUMBER(10)
, OLE_NO_COPIES_RCVD VARCHAR2(40)
, OLE_NO_PARTS_RCVD VARCHAR2(40)
, OLE_ITM_LOC VARCHAR2(40)
, OLE_ITM_STATUS VARCHAR2(40)
, OLE_CLM_CNT NUMBER(5)
, OLE_CLM_DT DATE
, OLE_DNT_CLM VARCHAR2(2) default 'N'
, OLE_CLM_NT VARCHAR2(40)
, CONSTRAINT PUR_REQS_ITM_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_REQS_ITM_T
ADD CONSTRAINT PUR_REQS_ITM_TP1
PRIMARY KEY (REQS_ITM_ID)
/
CREATE INDEX PUR_REQS_ITM_TI1
ON PUR_REQS_ITM_T
(ITM_TYP_CD)
/
CREATE INDEX PUR_REQS_ITM_TI3
ON PUR_REQS_ITM_T
(REQS_ID)
/
CREATE INDEX PUR_REQS_ITM_TI2
ON PUR_REQS_ITM_T
(OLE_FRMT_ID)
/
CREATE INDEX PUR_REQS_ITM_TI4
ON PUR_REQS_ITM_T
(OLE_CAT_ID)
/
CREATE INDEX PUR_REQS_ITM_TI5
ON PUR_REQS_ITM_T
(OLE_REQ_SRC_TYP_ID)
/
CREATE INDEX PUR_REQS_ITM_TI6
ON PUR_REQS_ITM_T
(OLE_RQSTR_TYP_ID)
/
-----------------------------------------------------------------------------
-- PUR_REQS_ITM_USE_TAX_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_REQS_ITM_USE_TAX_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_REQS_ITM_USE_TAX_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_REQS_ITM_USE_TAX_T
(
REQS_ITM_USE_TAX_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, REQS_ITM_ID NUMBER(10)
, RATE_CD VARCHAR2(10) NOT NULL
, TAX_AMT NUMBER(19,4)
, FIN_COA_CD VARCHAR2(2) NOT NULL
, ACCOUNT_NBR VARCHAR2(7) NOT NULL
, FIN_OBJECT_CD VARCHAR2(4) NOT NULL
, CONSTRAINT PUR_REQS_ITM_USE_TAX_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_REQS_ITM_USE_TAX_T
ADD CONSTRAINT PUR_REQS_ITM_USE_TAX_TP1
PRIMARY KEY (REQS_ITM_USE_TAX_ID)
/
-----------------------------------------------------------------------------
-- PUR_REQS_SRC_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_REQS_SRC_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_REQS_SRC_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_REQS_SRC_T
(
REQS_SRC_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, REQS_SRC_DESC VARCHAR2(45) NOT NULL
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT PUR_REQS_SRC_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_REQS_SRC_T
ADD CONSTRAINT PUR_REQS_SRC_TP1
PRIMARY KEY (REQS_SRC_CD)
/
-----------------------------------------------------------------------------
-- PUR_REQS_STAT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_REQS_STAT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_REQS_STAT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_REQS_STAT_T
(
REQS_STAT_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, REQS_STAT_DESC VARCHAR2(45) NOT NULL
, CONSTRAINT PUR_REQS_STAT_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_REQS_STAT_T
ADD CONSTRAINT PUR_REQS_STAT_TP1
PRIMARY KEY (REQS_STAT_CD)
/
-----------------------------------------------------------------------------
-- PUR_REQS_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_REQS_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_REQS_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_REQS_T
(
REQS_ID NUMBER(8)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FDOC_NBR VARCHAR2(14) NOT NULL
, FND_SRC_CD VARCHAR2(4)
, REQS_SRC_CD VARCHAR2(4) NOT NULL
, PO_TRNS_MTHD_CD VARCHAR2(4)
, PO_CST_SRC_CD VARCHAR2(4) NOT NULL
, DLVY_REQ_DT_REAS_CD VARCHAR2(4)
, RECUR_PMT_TYP_CD VARCHAR2(4)
, FIN_COA_CD VARCHAR2(2)
, ORG_CD VARCHAR2(4)
, DLVY_CMP_CD VARCHAR2(2) NOT NULL
, PO_ENCUM_FSCL_YR NUMBER(4) NOT NULL
, PO_TOT_LMT NUMBER(19,2)
, VNDR_HDR_GNRTD_ID NUMBER(10)
, VNDR_DTL_ASND_ID NUMBER(10)
, VNDR_NM VARCHAR2(45)
, VNDR_LN1_ADDR VARCHAR2(45)
, VNDR_LN2_ADDR VARCHAR2(45)
, VNDR_CTY_NM VARCHAR2(45)
, VNDR_ST_CD VARCHAR2(2)
, VNDR_PSTL_CD VARCHAR2(20)
, VNDR_CNTRY_CD VARCHAR2(2)
, VNDR_RSTRC_IND VARCHAR2(1)
, VNDR_PHN_NBR VARCHAR2(45)
, VNDR_FAX_NBR VARCHAR2(40)
, VNDR_CUST_NBR VARCHAR2(30)
, VNDR_CONTR_GNRTD_ID NUMBER(10)
, VNDR_NTE_TXT VARCHAR2(255)
, RQSTR_PRSN_NM VARCHAR2(45)
, RQSTR_PRSN_EMAIL_ADDR VARCHAR2(100)
, RQSTR_PRSN_PHN_NBR VARCHAR2(45)
, NON_INST_FND_ORG_COA_CD VARCHAR2(2)
, NON_INST_FND_ORG_CD VARCHAR2(4)
, NON_INST_FND_COA_CD VARCHAR2(2)
, NON_INST_FND_ACCT_NBR VARCHAR2(7)
, DLVY_BLDG_CD VARCHAR2(10)
, DLVY_BLDG_NM VARCHAR2(45)
, DLVY_BLDG_RM_NBR VARCHAR2(8)
, DLVY_BLDG_LN1_ADDR VARCHAR2(45)
, DLVY_BLDG_LN2_ADDR VARCHAR2(45)
, DLVY_CTY_NM VARCHAR2(45)
, DLVY_ST_CD VARCHAR2(2)
, DLVY_PSTL_CD VARCHAR2(20)
, DLVY_CNTRY_CD VARCHAR2(2)
, DLVY_TO_NM VARCHAR2(45)
, DLVY_TO_EMAIL_ADDR VARCHAR2(100)
, DLVY_TO_PHN_NBR VARCHAR2(45)
, DLVY_REQ_DT DATE
, DLVY_INSTRC_TXT VARCHAR2(255)
, REQS_ORG_REF_1_TXT VARCHAR2(20)
, REQS_ORG_REF_2_TXT VARCHAR2(20)
, REQS_ORG_REF_3_TXT VARCHAR2(20)
, PO_BEG_DT DATE
, PO_END_DT DATE
, INST_CNTCT_NM VARCHAR2(45)
, INST_CNTCT_PHN_NBR VARCHAR2(45)
, INST_CNTCT_EMAIL_ADDR VARCHAR2(100)
, ALTRNT_1_VNDR_NM VARCHAR2(45)
, ALTRNT_2_VNDR_NM VARCHAR2(45)
, ALTRNT_3_VNDR_NM VARCHAR2(45)
, ALTRNT_4_VNDR_NM VARCHAR2(45)
, ALTRNT_5_VNDR_NM VARCHAR2(45)
, BILL_NM VARCHAR2(45) NOT NULL
, BILL_LN1_ADDR VARCHAR2(45) NOT NULL
, BILL_LN2_ADDR VARCHAR2(45)
, BILL_CTY_NM VARCHAR2(45) NOT NULL
, BILL_ST_CD VARCHAR2(2) NOT NULL
, BILL_PSTL_CD VARCHAR2(20) NOT NULL
, BILL_CNTRY_CD VARCHAR2(2) NOT NULL
, BILL_PHN_NBR VARCHAR2(20) NOT NULL
, EXT_ORG_B2B_SUPP_ID VARCHAR2(19)
, ORG_AUTO_PO_LMT NUMBER(19,2)
, PO_AUTO_IND VARCHAR2(1)
, AP_PUR_DOC_LNK_ID NUMBER(10)
, VNDR_ADDR_INTL_PROV_NM VARCHAR2(45)
, RCVNG_DOC_REQ_IND VARCHAR2(1) default 'Y'
, PMT_RQST_PSTV_APRVL_IND VARCHAR2(1)
, CPTL_AST_SYS_TYP_CD VARCHAR2(4)
, PUR_RCVNG_NM VARCHAR2(45)
, PUR_RCVNG_LN1_ADDR VARCHAR2(45)
, PUR_RCVNG_LN2_ADDR VARCHAR2(45)
, PUR_RCVNG_CTY_NM VARCHAR2(45)
, PUR_RCVNG_ST_CD VARCHAR2(2)
, PUR_RCVNG_PSTL_CD VARCHAR2(20)
, PUR_RCVNG_CNTRY_CD VARCHAR2(2)
, CPTL_AST_SYS_ST_CD VARCHAR2(4)
, PUR_RCVNG_ADDR_TO_VNDR_IND VARCHAR2(1)
, USE_TAX_IND VARCHAR2(1) default 'Y' NOT NULL
, DLVY_BLDG_OTHR_IND VARCHAR2(1)
, VNDR_ATTN_NM VARCHAR2(45)
, OLE_REQSTR_TYP_ID NUMBER(22)
, OLE_VNDR_TRANS_FRMT_ID NUMBER(8)
, OLE_PO_TYPE_ID NUMBER(8) default 1
, OLE_VNDR_PO_ID VARCHAR2(100)
, OLE_TRANS_TYP_ID NUMBER(10)
, ACCT_DISTR_MTD_IND VARCHAR2(1) default 'P' NOT NULL
, VNDR_DEBRD_REAS_TXT VARCHAR2(255)
, BILL_EMAIL_ADDR VARCHAR2(100)
, LIC_REQ_IND VARCHAR2(1) default 'N'
, LIC_RQMT_CD VARCHAR2(20)
, CONSTRAINT PUR_REQS_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_REQS_T
ADD CONSTRAINT PUR_REQS_TP1
PRIMARY KEY (REQS_ID)
/
CREATE INDEX PUR_REQS_TI1
ON PUR_REQS_T
(REQS_SRC_CD)
/
CREATE INDEX PUR_REQS_TI2
ON PUR_REQS_T
(FND_SRC_CD)
/
CREATE INDEX PUR_REQS_TI4
ON PUR_REQS_T
(PO_TRNS_MTHD_CD)
/
CREATE INDEX PUR_REQS_TI5
ON PUR_REQS_T
(RECUR_PMT_TYP_CD)
/
CREATE INDEX PUR_REQS_TI6
ON PUR_REQS_T
(DLVY_REQ_DT_REAS_CD)
/
CREATE INDEX PUR_REQS_TI7
ON PUR_REQS_T
(FDOC_NBR)
/
CREATE INDEX PUR_REQS_TI8
ON PUR_REQS_T
(PO_CST_SRC_CD)
/
CREATE INDEX PUR_REQS_TI9
ON PUR_REQS_T
(AP_PUR_DOC_LNK_ID)
/
-----------------------------------------------------------------------------
-- PUR_SHP_PMT_TERM_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_SHP_PMT_TERM_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_SHP_PMT_TERM_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_SHP_PMT_TERM_T
(
VNDR_SHP_PMT_TERM_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, VNDR_SHP_PMT_TERM_DESC VARCHAR2(45)
, VNDR_SHP_PMT_TERM_PAY_IND VARCHAR2(1)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT PUR_SHP_PMT_TERM_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_SHP_PMT_TERM_T
ADD CONSTRAINT PUR_SHP_PMT_TERM_TP1
PRIMARY KEY (VNDR_SHP_PMT_TERM_CD)
/
-----------------------------------------------------------------------------
-- PUR_SHP_SPCL_COND_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_SHP_SPCL_COND_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_SHP_SPCL_COND_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_SHP_SPCL_COND_T
(
VNDR_SHP_SPCL_COND_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, VNDR_SHP_SPCL_COND_DESC VARCHAR2(45)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT PUR_SHP_SPCL_COND_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_SHP_SPCL_COND_T
ADD CONSTRAINT PUR_SHP_SPCL_COND_TP1
PRIMARY KEY (VNDR_SHP_SPCL_COND_CD)
/
-----------------------------------------------------------------------------
-- PUR_SHP_TTL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_SHP_TTL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_SHP_TTL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_SHP_TTL_T
(
VNDR_SHP_TTL_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, VNDR_SHP_TTL_DESC VARCHAR2(45)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT PUR_SHP_TTL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_SHP_TTL_T
ADD CONSTRAINT PUR_SHP_TTL_TP1
PRIMARY KEY (VNDR_SHP_TTL_CD)
/
-----------------------------------------------------------------------------
-- PUR_SNSTV_DTA_ASGN_DTL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_SNSTV_DTA_ASGN_DTL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_SNSTV_DTA_ASGN_DTL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_SNSTV_DTA_ASGN_DTL_T
(
SNSTV_DTA_ASGN_ID NUMBER(9)
, SNSTV_DTA_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, CONSTRAINT PUR_SNSTV_DTA_ASGN_DTL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_SNSTV_DTA_ASGN_DTL_T
ADD CONSTRAINT PUR_SNSTV_DTA_ASGN_DTL_TP1
PRIMARY KEY (SNSTV_DTA_ASGN_ID,SNSTV_DTA_CD)
/
-----------------------------------------------------------------------------
-- PUR_SNSTV_DTA_ASGN_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_SNSTV_DTA_ASGN_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_SNSTV_DTA_ASGN_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_SNSTV_DTA_ASGN_T
(
SNSTV_DTA_ASGN_ID NUMBER(9)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, PO_ID NUMBER(9) NOT NULL
, SNSTV_DTA_ASGN_REAS_TXT VARCHAR2(500)
, SNSTV_DTA_ASGN_CHG_PRSN_ID VARCHAR2(40)
, SNSTV_DTA_ASGN_CHG_DT DATE
, CONSTRAINT PUR_SNSTV_DTA_ASGN_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_SNSTV_DTA_ASGN_T
ADD CONSTRAINT PUR_SNSTV_DTA_ASGN_TP1
PRIMARY KEY (SNSTV_DTA_ASGN_ID)
/
-----------------------------------------------------------------------------
-- PUR_SNSTV_DTA_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_SNSTV_DTA_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_SNSTV_DTA_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_SNSTV_DTA_T
(
SNSTV_DTA_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, SNSTV_DTA_DESC VARCHAR2(45) NOT NULL
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT PUR_SNSTV_DTA_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_SNSTV_DTA_T
ADD CONSTRAINT PUR_SNSTV_DTA_TP1
PRIMARY KEY (SNSTV_DTA_CD)
/
-----------------------------------------------------------------------------
-- PUR_SUPP_DVRST_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_SUPP_DVRST_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_SUPP_DVRST_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_SUPP_DVRST_T
(
VNDR_SUPP_DVRST_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, VNDR_SUPP_DVRST_DESC VARCHAR2(45)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT PUR_SUPP_DVRST_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_SUPP_DVRST_T
ADD CONSTRAINT PUR_SUPP_DVRST_TP1
PRIMARY KEY (VNDR_SUPP_DVRST_CD)
/
-----------------------------------------------------------------------------
-- PUR_THRSHLD_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_THRSHLD_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_THRSHLD_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_THRSHLD_T
(
PUR_THRSHLD_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FIN_COA_CD VARCHAR2(2)
, ACCT_TYP_CD VARCHAR2(2)
, SUB_FUND_GRP_CD VARCHAR2(6)
, FIN_OBJECT_CD VARCHAR2(4)
, ORG_CD VARCHAR2(4)
, PUR_THRSHLD_AMT NUMBER(19,2)
, VNDR_HDR_GNRTD_ID NUMBER(10)
, VNDR_DTL_ASND_ID NUMBER(10)
, PUR_COMM_CD VARCHAR2(40)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT PUR_THRSHLD_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_THRSHLD_T
ADD CONSTRAINT PUR_THRSHLD_TP1
PRIMARY KEY (PUR_THRSHLD_ID)
/
-----------------------------------------------------------------------------
-- PUR_VNDR_ADDR_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_VNDR_ADDR_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_VNDR_ADDR_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_VNDR_ADDR_T
(
VNDR_ADDR_GNRTD_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, VNDR_HDR_GNRTD_ID NUMBER(10) NOT NULL
, VNDR_DTL_ASND_ID NUMBER(10) NOT NULL
, VNDR_ADDR_TYP_CD VARCHAR2(4) NOT NULL
, VNDR_LN1_ADDR VARCHAR2(45)
, VNDR_LN2_ADDR VARCHAR2(45)
, VNDR_CTY_NM VARCHAR2(45)
, VNDR_ST_CD VARCHAR2(2)
, VNDR_ZIP_CD VARCHAR2(20)
, VNDR_CNTRY_CD VARCHAR2(2)
, VNDR_ATTN_NM VARCHAR2(45)
, VNDR_ADDR_INTL_PROV_NM VARCHAR2(45)
, VNDR_ADDR_EMAIL_ADDR VARCHAR2(90)
, VNDR_B2B_URL_ADDR VARCHAR2(90)
, VNDR_FAX_NBR VARCHAR2(40)
, VNDR_DFLT_ADDR_IND VARCHAR2(1)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, VNDR_ACCOUNT_NBR VARCHAR2(7)
, VNDR_FIN_COA_CD VARCHAR2(2)
, OLE_VNDR_ADDR_NT VARCHAR2(400)
, CONSTRAINT PUR_VNDR_ADDR_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_VNDR_ADDR_T
ADD CONSTRAINT PUR_VNDR_ADDR_TP1
PRIMARY KEY (VNDR_ADDR_GNRTD_ID)
/
CREATE INDEX PUR_VNDR_ADDR_TI1
ON PUR_VNDR_ADDR_T
(VNDR_HDR_GNRTD_ID, VNDR_DTL_ASND_ID)
/
-----------------------------------------------------------------------------
-- PUR_VNDR_ALIAS_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_VNDR_ALIAS_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_VNDR_ALIAS_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_VNDR_ALIAS_T
(
VNDR_ALIAS_NM VARCHAR2(45)
, VNDR_HDR_GNRTD_ID NUMBER(10)
, VNDR_DTL_ASND_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, OLE_ALIAS_TYP_ID NUMBER(8)
, OLE_PUR_VNDR_ALIAS_ID NUMBER(10)
, CONSTRAINT PUR_VNDR_ALIAS_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_VNDR_ALIAS_T
ADD CONSTRAINT PUR_VNDR_ALIAS_TP1
PRIMARY KEY (VNDR_HDR_GNRTD_ID,VNDR_DTL_ASND_ID,OLE_PUR_VNDR_ALIAS_ID)
/
CREATE INDEX PUR_VNDR_ALIAS_TI1
ON PUR_VNDR_ALIAS_T
(VNDR_HDR_GNRTD_ID)
/
-----------------------------------------------------------------------------
-- PUR_VNDR_CNTCT_PHN_NBR_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_VNDR_CNTCT_PHN_NBR_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_VNDR_CNTCT_PHN_NBR_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_VNDR_CNTCT_PHN_NBR_T
(
VNDR_CNTCT_PHN_GNRTD_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, VNDR_CNTCT_GNRTD_ID NUMBER(10) NOT NULL
, VNDR_PHN_TYP_CD VARCHAR2(4) NOT NULL
, VNDR_PHN_NBR VARCHAR2(40)
, VNDR_PHN_EXTNS_NBR VARCHAR2(10)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT PUR_VNDR_CNTCT_PHN_NBR_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_VNDR_CNTCT_PHN_NBR_T
ADD CONSTRAINT PUR_VNDR_CNTCT_PHN_NBR_TP1
PRIMARY KEY (VNDR_CNTCT_PHN_GNRTD_ID)
/
-----------------------------------------------------------------------------
-- PUR_VNDR_CNTCT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_VNDR_CNTCT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_VNDR_CNTCT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_VNDR_CNTCT_T
(
VNDR_CNTCT_GNRTD_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, VNDR_HDR_GNRTD_ID NUMBER(10) NOT NULL
, VNDR_DTL_ASND_ID NUMBER(10) NOT NULL
, VNDR_CNTCT_TYP_CD VARCHAR2(4) NOT NULL
, VNDR_CNTCT_NM VARCHAR2(45)
, VNDR_CNTCT_EMAIL_ADDR VARCHAR2(90)
, VNDR_CNTCT_CMNT_TXT VARCHAR2(800)
, VNDR_LN1_ADDR VARCHAR2(45)
, VNDR_LN2_ADDR VARCHAR2(45)
, VNDR_CTY_NM VARCHAR2(45)
, VNDR_ST_CD VARCHAR2(2)
, VNDR_ZIP_CD VARCHAR2(20)
, VNDR_CNTRY_CD VARCHAR2(2)
, VNDR_ATTN_NM VARCHAR2(45)
, VNDR_ADDR_INTL_PROV_NM VARCHAR2(45)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, VNDR_ACCOUNT_NBR VARCHAR2(7)
, VNDR_FIN_COA_CD VARCHAR2(2)
, CONSTRAINT PUR_VNDR_CNTCT_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_VNDR_CNTCT_T
ADD CONSTRAINT PUR_VNDR_CNTCT_TP1
PRIMARY KEY (VNDR_CNTCT_GNRTD_ID)
/
-----------------------------------------------------------------------------
-- PUR_VNDR_COMM_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_VNDR_COMM_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_VNDR_COMM_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_VNDR_COMM_T
(
VNDR_HDR_GNRTD_ID NUMBER(10)
, VNDR_DTL_ASND_ID NUMBER(10)
, PUR_COMM_CD VARCHAR2(40)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, PUR_COMM_DFLT_IND VARCHAR2(1)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT PUR_VNDR_COMM_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_VNDR_COMM_T
ADD CONSTRAINT PUR_VNDR_COMM_TP1
PRIMARY KEY (VNDR_HDR_GNRTD_ID,VNDR_DTL_ASND_ID,PUR_COMM_CD)
/
-----------------------------------------------------------------------------
-- PUR_VNDR_CONTR_ORG_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_VNDR_CONTR_ORG_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_VNDR_CONTR_ORG_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_VNDR_CONTR_ORG_T
(
VNDR_CONTR_GNRTD_ID NUMBER(10)
, FIN_COA_CD VARCHAR2(2)
, ORG_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, VNDR_CTRPO_LMT_AMT NUMBER(19,2)
, VNDR_CONTR_EXCL_IND VARCHAR2(2)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT PUR_VNDR_CONTR_ORG_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_VNDR_CONTR_ORG_T
ADD CONSTRAINT PUR_VNDR_CONTR_ORG_TP1
PRIMARY KEY (VNDR_CONTR_GNRTD_ID,FIN_COA_CD,ORG_CD)
/
-----------------------------------------------------------------------------
-- PUR_VNDR_CONTR_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_VNDR_CONTR_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_VNDR_CONTR_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_VNDR_CONTR_T
(
VNDR_CONTR_GNRTD_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, VNDR_HDR_GNRTD_ID NUMBER(10) NOT NULL
, VNDR_DTL_ASND_ID NUMBER(10) NOT NULL
, VNDR_CONTR_NM VARCHAR2(20)
, VNDR_CONTR_DESC VARCHAR2(60)
, VNDR_CMP_CD VARCHAR2(2)
, VNDR_CONTR_BEG_DT DATE
, VNDR_CONTR_END_DT DATE
, CONTR_MGR_CD NUMBER(2)
, PO_CST_SRC_CD VARCHAR2(4)
, VNDR_PMT_TERM_CD VARCHAR2(5)
, VNDR_SHP_PMT_TERM_CD VARCHAR2(4)
, VNDR_SHP_TTL_CD VARCHAR2(4)
, VNDR_CONTR_EXTNS_DT DATE
, VNDR_B2B_IND VARCHAR2(1)
, ORG_AUTO_PO_LMT NUMBER(19,2)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT PUR_VNDR_CONTR_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_VNDR_CONTR_T
ADD CONSTRAINT PUR_VNDR_CONTR_TP1
PRIMARY KEY (VNDR_CONTR_GNRTD_ID)
/
-----------------------------------------------------------------------------
-- PUR_VNDR_CUST_NBR_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_VNDR_CUST_NBR_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_VNDR_CUST_NBR_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_VNDR_CUST_NBR_T
(
VNDR_CUST_NBR_GNRTD_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, VNDR_HDR_GNRTD_ID NUMBER(10) NOT NULL
, VNDR_DTL_ASND_ID NUMBER(10) NOT NULL
, VNDR_CUST_NBR VARCHAR2(30) NOT NULL
, FIN_COA_CD VARCHAR2(2)
, VNDR_ORG_CD VARCHAR2(4)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, OLE_STD_DEL_CARR_INT NUMBER(6,2)
, CARI_CD VARCHAR2(4)
, OLE_DISCNT NUMBER(19,4)
, OLE_VNDR_DISCNT_TYP VARCHAR2(1)
, CONSTRAINT PUR_VNDR_CUST_NBR_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_VNDR_CUST_NBR_T
ADD CONSTRAINT PUR_VNDR_CUST_NBR_TP1
PRIMARY KEY (VNDR_CUST_NBR_GNRTD_ID)
/
-----------------------------------------------------------------------------
-- PUR_VNDR_DFLT_ADDR_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_VNDR_DFLT_ADDR_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_VNDR_DFLT_ADDR_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_VNDR_DFLT_ADDR_T
(
VNDR_DFLT_ADDR_GNRTD_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, VNDR_ADDR_GNRTD_ID NUMBER(10) NOT NULL
, VNDR_CMP_CD VARCHAR2(2)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT PUR_VNDR_DFLT_ADDR_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_VNDR_DFLT_ADDR_T
ADD CONSTRAINT PUR_VNDR_DFLT_ADDR_TP1
PRIMARY KEY (VNDR_DFLT_ADDR_GNRTD_ID)
/
CREATE INDEX PUR_VNDR_DFLT_ADDR_TI1
ON PUR_VNDR_DFLT_ADDR_T
(VNDR_ADDR_GNRTD_ID)
/
-----------------------------------------------------------------------------
-- PUR_VNDR_DTL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_VNDR_DTL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_VNDR_DTL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_VNDR_DTL_T
(
VNDR_HDR_GNRTD_ID NUMBER(10)
, VNDR_DTL_ASND_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, VNDR_PARENT_IND VARCHAR2(1)
, VNDR_NM VARCHAR2(45) NOT NULL
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, VNDR_INACTV_REAS_CD VARCHAR2(4)
, VNDR_DUNS_NBR VARCHAR2(9)
, VNDR_PMT_TERM_CD VARCHAR2(5)
, VNDR_SHP_TTL_CD VARCHAR2(4)
, VNDR_SHP_PMT_TERM_CD VARCHAR2(4)
, VNDR_CNFM_IND VARCHAR2(1)
, VNDR_PRPYMT_IND VARCHAR2(1)
, VNDR_CCRD_IND VARCHAR2(1)
, VNDR_MIN_ORD_AMT NUMBER(7,2)
, VNDR_URL_ADDR VARCHAR2(45)
, VNDR_SOLD_TO_NM VARCHAR2(100)
, VNDR_RMT_NM VARCHAR2(45)
, VNDR_RSTRC_IND VARCHAR2(1)
, VNDR_RSTRC_REAS_TXT VARCHAR2(60)
, VNDR_RSTRC_DT DATE
, VNDR_RSTRC_PRSN_ID VARCHAR2(40)
, VNDR_SOLD_TO_GNRTD_ID NUMBER(10)
, VNDR_SOLD_TO_ASND_ID NUMBER(10)
, VNDR_1ST_LST_NM_IND VARCHAR2(1)
, COLLECT_TAX_IND VARCHAR2(1) default 'Y' NOT NULL
, OLE_CURR_TYP_ID NUMBER(8)
, VNDR_PMT_MTHD_ID NUMBER(10)
, VNDR_LINK_ID VARCHAR2(40)
, VNDR_CLM_INTRVL VARCHAR2(40)
, CONSTRAINT PUR_VNDR_DTL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_VNDR_DTL_T
ADD CONSTRAINT PUR_VNDR_DTL_TP1
PRIMARY KEY (VNDR_HDR_GNRTD_ID,VNDR_DTL_ASND_ID)
/
-----------------------------------------------------------------------------
-- PUR_VNDR_EXCL_MT
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_VNDR_EXCL_MT';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_VNDR_EXCL_MT CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_VNDR_EXCL_MT
(
VNDR_EXCL_ID NUMBER(10)
, VNDR_EXCL_LOAD_DT DATE
, VNDR_EXCL_NM VARCHAR2(200)
, VNDR_EXCL_LN1_ADDR VARCHAR2(150)
, VNDR_EXCL_LN2_ADDR VARCHAR2(50)
, VNDR_EXCL_CTY_NM VARCHAR2(50)
, VNDR_EXCL_ST_CD VARCHAR2(2)
, VNDR_EXCL_PRVN_NM VARCHAR2(20)
, VNDR_EXCL_ZIP_CD VARCHAR2(20)
, VNDR_EXCL_OTHR_NM VARCHAR2(1000)
, VNDR_EXCL_DESC_TXT VARCHAR2(1000)
)
/
ALTER TABLE PUR_VNDR_EXCL_MT
ADD CONSTRAINT PUR_VNDR_EXCL_MTP1
PRIMARY KEY (VNDR_EXCL_ID)
/
-----------------------------------------------------------------------------
-- PUR_VNDR_EXCL_MTCH_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_VNDR_EXCL_MTCH_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_VNDR_EXCL_MTCH_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_VNDR_EXCL_MTCH_T
(
VNDR_EXCL_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, VNDR_HDR_GNRTD_ID NUMBER(10)
, VNDR_DTL_ASND_ID NUMBER(10)
, VNDR_ADDR_GNRTD_ID NUMBER(10)
, VNDR_EXCL_CFRM_STAT_CD VARCHAR2(10)
, VNDR_EXCL_LOAD_DT DATE
, VNDR_EXCL_NM VARCHAR2(200)
, VNDR_EXCL_LN1_ADDR VARCHAR2(150)
, VNDR_EXCL_LN2_ADDR VARCHAR2(50)
, VNDR_EXCL_CTY_NM VARCHAR2(50)
, VNDR_EXCL_ST_CD VARCHAR2(2)
, VNDR_EXCL_PRVN_NM VARCHAR2(20)
, VNDR_EXCL_ZIP_CD VARCHAR2(20)
, VNDR_EXCL_OTHR_NM VARCHAR2(1000)
, VNDR_EXCL_DESC_TXT VARCHAR2(1000)
, LST_UPDT_TS DATE
, LST_UPDT_PRNCPL_NM VARCHAR2(100)
, CONSTRAINT PUR_VNDR_EXCL_MTCH_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_VNDR_EXCL_MTCH_T
ADD CONSTRAINT PUR_VNDR_EXCL_MTCH_TP1
PRIMARY KEY (VNDR_EXCL_ID)
/
-----------------------------------------------------------------------------
-- PUR_VNDR_HDR_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_VNDR_HDR_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_VNDR_HDR_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_VNDR_HDR_T
(
VNDR_HDR_GNRTD_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, VNDR_TYP_CD VARCHAR2(4) NOT NULL
, VNDR_TAX_NBR VARCHAR2(255)
, VNDR_TAX_TYP_CD VARCHAR2(4)
, VNDR_OWNR_CD VARCHAR2(4)
, VNDR_OWNR_CTGRY_CD VARCHAR2(4)
, VNDR_FWT_BEG_DT DATE
, VNDR_FWT_END_DT DATE
, VNDR_W9_RCVD_IND VARCHAR2(1)
, VNDR_W8_BEN_RCVD_IND VARCHAR2(1)
, VNDR_DEBRD_IND VARCHAR2(1)
, VNDR_FRGN_IND VARCHAR2(1)
, CONSTRAINT PUR_VNDR_HDR_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_VNDR_HDR_T
ADD CONSTRAINT PUR_VNDR_HDR_TP1
PRIMARY KEY (VNDR_HDR_GNRTD_ID)
/
-----------------------------------------------------------------------------
-- PUR_VNDR_INACTV_REAS_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_VNDR_INACTV_REAS_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_VNDR_INACTV_REAS_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_VNDR_INACTV_REAS_T
(
VNDR_INACTV_REAS_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, VNDR_INACTV_REAS_DESC VARCHAR2(45)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT PUR_VNDR_INACTV_REAS_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_VNDR_INACTV_REAS_T
ADD CONSTRAINT PUR_VNDR_INACTV_REAS_TP1
PRIMARY KEY (VNDR_INACTV_REAS_CD)
/
-----------------------------------------------------------------------------
-- PUR_VNDR_PHN_NBR_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_VNDR_PHN_NBR_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_VNDR_PHN_NBR_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_VNDR_PHN_NBR_T
(
VNDR_PHN_GNRTD_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, VNDR_HDR_GNRTD_ID NUMBER(10) NOT NULL
, VNDR_DTL_ASND_ID NUMBER(10) NOT NULL
, VNDR_PHN_TYP_CD VARCHAR2(4) NOT NULL
, VNDR_PHN_NBR VARCHAR2(40)
, VNDR_PHN_EXTNS_NBR VARCHAR2(10)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT PUR_VNDR_PHN_NBR_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_VNDR_PHN_NBR_T
ADD CONSTRAINT PUR_VNDR_PHN_NBR_TP1
PRIMARY KEY (VNDR_PHN_GNRTD_ID)
/
-----------------------------------------------------------------------------
-- PUR_VNDR_SHP_SPCL_COND_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_VNDR_SHP_SPCL_COND_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_VNDR_SHP_SPCL_COND_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_VNDR_SHP_SPCL_COND_T
(
VNDR_HDR_GNRTD_ID NUMBER(10)
, VNDR_DTL_ASND_ID NUMBER(10)
, VNDR_SHP_SPCL_COND_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT PUR_VNDR_SHP_SPCL_COND_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_VNDR_SHP_SPCL_COND_T
ADD CONSTRAINT PUR_VNDR_SHP_SPCL_COND_TP1
PRIMARY KEY (VNDR_HDR_GNRTD_ID,VNDR_DTL_ASND_ID,VNDR_SHP_SPCL_COND_CD)
/
-----------------------------------------------------------------------------
-- PUR_VNDR_STPLTN_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_VNDR_STPLTN_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_VNDR_STPLTN_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_VNDR_STPLTN_T
(
VNDR_STPLTN_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, VNDR_STPLTN_NM VARCHAR2(40) NOT NULL
, VNDR_STPLTN_DESC VARCHAR2(4000) NOT NULL
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT PUR_VNDR_STPLTN_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_VNDR_STPLTN_T
ADD CONSTRAINT PUR_VNDR_STPLTN_TP1
PRIMARY KEY (VNDR_STPLTN_ID)
/
-----------------------------------------------------------------------------
-- PUR_VNDR_SUPP_DVRST_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_VNDR_SUPP_DVRST_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_VNDR_SUPP_DVRST_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_VNDR_SUPP_DVRST_T
(
VNDR_HDR_GNRTD_ID NUMBER(10)
, VNDR_SUPP_DVRST_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT PUR_VNDR_SUPP_DVRST_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_VNDR_SUPP_DVRST_T
ADD CONSTRAINT PUR_VNDR_SUPP_DVRST_TP1
PRIMARY KEY (VNDR_HDR_GNRTD_ID,VNDR_SUPP_DVRST_CD)
/
-----------------------------------------------------------------------------
-- PUR_VNDR_TAX_CHG_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_VNDR_TAX_CHG_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_VNDR_TAX_CHG_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_VNDR_TAX_CHG_T
(
VNDR_TAX_CHG_GNRTD_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, VNDR_HDR_GNRTD_ID NUMBER(10) NOT NULL
, VNDR_TAX_CHG_DT DATE NOT NULL
, VNDR_PREV_TAX_NBR VARCHAR2(255)
, VNDR_PREV_TAX_TYP_CD VARCHAR2(4)
, VNDR_TAX_CHG_PRSN_ID VARCHAR2(40) NOT NULL
, CONSTRAINT PUR_VNDR_TAX_CHG_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_VNDR_TAX_CHG_T
ADD CONSTRAINT PUR_VNDR_TAX_CHG_TP1
PRIMARY KEY (VNDR_TAX_CHG_GNRTD_ID)
/
-----------------------------------------------------------------------------
-- PUR_VNDR_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'PUR_VNDR_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE PUR_VNDR_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE PUR_VNDR_TYP_T
(
VNDR_TYP_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, VNDR_TYP_DESC VARCHAR2(45)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, VNDR_TAX_NBR_REQ_IND VARCHAR2(1)
, VNDR_TYP_CHG_ALLW_IND VARCHAR2(1)
, VNDR_ADDR_TYP_REQ_CD VARCHAR2(4)
, VNDR_CONTR_ALLW_IND VARCHAR2(1)
, VNDR_SHOW_RVW_IND VARCHAR2(1)
, VNDR_RVW_TXT VARCHAR2(4000)
, PUR_COMM_REQ_IND VARCHAR2(1)
, CONSTRAINT PUR_VNDR_TYP_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE PUR_VNDR_TYP_T
ADD CONSTRAINT PUR_VNDR_TYP_TP1
PRIMARY KEY (VNDR_TYP_CD)
/
-----------------------------------------------------------------------------
-- QRTZ_BLOB_TRIGGERS
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'QRTZ_BLOB_TRIGGERS';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE QRTZ_BLOB_TRIGGERS CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE QRTZ_BLOB_TRIGGERS
(
TRIGGER_NAME VARCHAR2(80)
, TRIGGER_GROUP VARCHAR2(80)
, BLOB_DATA BLOB
)
/
ALTER TABLE QRTZ_BLOB_TRIGGERS
ADD CONSTRAINT QRTZ_BLOB_TRIGGERSP1
PRIMARY KEY (TRIGGER_NAME,TRIGGER_GROUP)
/
-----------------------------------------------------------------------------
-- QRTZ_CALENDARS
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'QRTZ_CALENDARS';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE QRTZ_CALENDARS CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE QRTZ_CALENDARS
(
CALENDAR_NAME VARCHAR2(80)
, CALENDAR BLOB NOT NULL
)
/
ALTER TABLE QRTZ_CALENDARS
ADD CONSTRAINT QRTZ_CALENDARSP1
PRIMARY KEY (CALENDAR_NAME)
/
-----------------------------------------------------------------------------
-- QRTZ_CRON_TRIGGERS
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'QRTZ_CRON_TRIGGERS';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE QRTZ_CRON_TRIGGERS CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE QRTZ_CRON_TRIGGERS
(
TRIGGER_NAME VARCHAR2(80)
, TRIGGER_GROUP VARCHAR2(80)
, CRON_EXPRESSION VARCHAR2(80) NOT NULL
, TIME_ZONE_ID VARCHAR2(80)
)
/
ALTER TABLE QRTZ_CRON_TRIGGERS
ADD CONSTRAINT QRTZ_CRON_TRIGGERSP1
PRIMARY KEY (TRIGGER_NAME,TRIGGER_GROUP)
/
-----------------------------------------------------------------------------
-- QRTZ_FIRED_TRIGGERS
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'QRTZ_FIRED_TRIGGERS';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE QRTZ_FIRED_TRIGGERS CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE QRTZ_FIRED_TRIGGERS
(
ENTRY_ID VARCHAR2(95)
, TRIGGER_NAME VARCHAR2(80) NOT NULL
, TRIGGER_GROUP VARCHAR2(80) NOT NULL
, IS_VOLATILE VARCHAR2(1) NOT NULL
, INSTANCE_NAME VARCHAR2(80) NOT NULL
, FIRED_TIME NUMBER(13) NOT NULL
, PRIORITY NUMBER(13) NOT NULL
, STATE VARCHAR2(16) NOT NULL
, JOB_NAME VARCHAR2(80)
, JOB_GROUP VARCHAR2(80)
, IS_STATEFUL VARCHAR2(1)
, REQUESTS_RECOVERY VARCHAR2(1)
)
/
ALTER TABLE QRTZ_FIRED_TRIGGERS
ADD CONSTRAINT QRTZ_FIRED_TRIGGERSP1
PRIMARY KEY (ENTRY_ID)
/
CREATE INDEX IDX_QRTZ_FT_JOB_GROUP
ON QRTZ_FIRED_TRIGGERS
(JOB_GROUP)
/
CREATE INDEX IDX_QRTZ_FT_JOB_NAME
ON QRTZ_FIRED_TRIGGERS
(JOB_NAME)
/
CREATE INDEX IDX_QRTZ_FT_JOB_REQ_RECOVERY
ON QRTZ_FIRED_TRIGGERS
(REQUESTS_RECOVERY)
/
CREATE INDEX IDX_QRTZ_FT_JOB_STATEFUL
ON QRTZ_FIRED_TRIGGERS
(IS_STATEFUL)
/
CREATE INDEX IDX_QRTZ_FT_TRIG_GROUP
ON QRTZ_FIRED_TRIGGERS
(TRIGGER_GROUP)
/
CREATE INDEX IDX_QRTZ_FT_TRIG_INST_NAME
ON QRTZ_FIRED_TRIGGERS
(INSTANCE_NAME)
/
CREATE INDEX IDX_QRTZ_FT_TRIG_NAME
ON QRTZ_FIRED_TRIGGERS
(TRIGGER_NAME)
/
CREATE INDEX IDX_QRTZ_FT_TRIG_NM_GP
ON QRTZ_FIRED_TRIGGERS
(TRIGGER_NAME, TRIGGER_GROUP)
/
CREATE INDEX IDX_QRTZ_FT_TRIG_VOLATILE
ON QRTZ_FIRED_TRIGGERS
(IS_VOLATILE)
/
-----------------------------------------------------------------------------
-- QRTZ_JOB_DETAILS
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'QRTZ_JOB_DETAILS';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE QRTZ_JOB_DETAILS CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE QRTZ_JOB_DETAILS
(
JOB_NAME VARCHAR2(80)
, JOB_GROUP VARCHAR2(80)
, DESCRIPTION VARCHAR2(120)
, JOB_CLASS_NAME VARCHAR2(128) NOT NULL
, IS_DURABLE VARCHAR2(1) NOT NULL
, IS_VOLATILE VARCHAR2(1) NOT NULL
, IS_STATEFUL VARCHAR2(1) NOT NULL
, REQUESTS_RECOVERY VARCHAR2(1) NOT NULL
, JOB_DATA BLOB
)
/
ALTER TABLE QRTZ_JOB_DETAILS
ADD CONSTRAINT QRTZ_JOB_DETAILSP1
PRIMARY KEY (JOB_NAME,JOB_GROUP)
/
CREATE INDEX IDX_QRTZ_J_REQ_RECOVERY
ON QRTZ_JOB_DETAILS
(REQUESTS_RECOVERY)
/
-----------------------------------------------------------------------------
-- QRTZ_JOB_LISTENERS
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'QRTZ_JOB_LISTENERS';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE QRTZ_JOB_LISTENERS CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE QRTZ_JOB_LISTENERS
(
JOB_NAME VARCHAR2(80)
, JOB_GROUP VARCHAR2(80)
, JOB_LISTENER VARCHAR2(80)
)
/
ALTER TABLE QRTZ_JOB_LISTENERS
ADD CONSTRAINT QRTZ_JOB_LISTENERSP1
PRIMARY KEY (JOB_NAME,JOB_GROUP,JOB_LISTENER)
/
-----------------------------------------------------------------------------
-- QRTZ_LOCKS
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'QRTZ_LOCKS';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE QRTZ_LOCKS CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE QRTZ_LOCKS
(
LOCK_NAME VARCHAR2(40)
)
/
ALTER TABLE QRTZ_LOCKS
ADD CONSTRAINT QRTZ_LOCKSP1
PRIMARY KEY (LOCK_NAME)
/
-----------------------------------------------------------------------------
-- QRTZ_PAUSED_TRIGGER_GRPS
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'QRTZ_PAUSED_TRIGGER_GRPS';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE QRTZ_PAUSED_TRIGGER_GRPS CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE QRTZ_PAUSED_TRIGGER_GRPS
(
TRIGGER_GROUP VARCHAR2(80)
)
/
ALTER TABLE QRTZ_PAUSED_TRIGGER_GRPS
ADD CONSTRAINT QRTZ_PAUSED_TRIGGER_GRPSP1
PRIMARY KEY (TRIGGER_GROUP)
/
-----------------------------------------------------------------------------
-- QRTZ_SCHEDULER_STATE
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'QRTZ_SCHEDULER_STATE';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE QRTZ_SCHEDULER_STATE CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE QRTZ_SCHEDULER_STATE
(
INSTANCE_NAME VARCHAR2(80)
, LAST_CHECKIN_TIME NUMBER(13) NOT NULL
, CHECKIN_INTERVAL NUMBER(13) NOT NULL
)
/
ALTER TABLE QRTZ_SCHEDULER_STATE
ADD CONSTRAINT QRTZ_SCHEDULER_STATEP1
PRIMARY KEY (INSTANCE_NAME)
/
-----------------------------------------------------------------------------
-- QRTZ_SIMPLE_TRIGGERS
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'QRTZ_SIMPLE_TRIGGERS';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE QRTZ_SIMPLE_TRIGGERS CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE QRTZ_SIMPLE_TRIGGERS
(
TRIGGER_NAME VARCHAR2(80)
, TRIGGER_GROUP VARCHAR2(80)
, REPEAT_COUNT NUMBER(7) NOT NULL
, REPEAT_INTERVAL NUMBER(12) NOT NULL
, TIMES_TRIGGERED NUMBER(7) NOT NULL
)
/
ALTER TABLE QRTZ_SIMPLE_TRIGGERS
ADD CONSTRAINT QRTZ_SIMPLE_TRIGGERSP1
PRIMARY KEY (TRIGGER_NAME,TRIGGER_GROUP)
/
-----------------------------------------------------------------------------
-- QRTZ_TRIGGERS
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'QRTZ_TRIGGERS';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE QRTZ_TRIGGERS CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE QRTZ_TRIGGERS
(
TRIGGER_NAME VARCHAR2(80)
, TRIGGER_GROUP VARCHAR2(80)
, JOB_NAME VARCHAR2(80) NOT NULL
, JOB_GROUP VARCHAR2(80) NOT NULL
, IS_VOLATILE VARCHAR2(1) NOT NULL
, DESCRIPTION VARCHAR2(120)
, NEXT_FIRE_TIME NUMBER(13)
, PREV_FIRE_TIME NUMBER(13)
, PRIORITY NUMBER(13)
, TRIGGER_STATE VARCHAR2(16) NOT NULL
, TRIGGER_TYPE VARCHAR2(8) NOT NULL
, START_TIME NUMBER(13) NOT NULL
, END_TIME NUMBER(13)
, CALENDAR_NAME VARCHAR2(80)
, MISFIRE_INSTR NUMBER(2)
, JOB_DATA BLOB
)
/
ALTER TABLE QRTZ_TRIGGERS
ADD CONSTRAINT QRTZ_TRIGGERSP1
PRIMARY KEY (TRIGGER_NAME,TRIGGER_GROUP)
/
CREATE INDEX IDX_QRTZ_T_NEXT_FIRE_TIME
ON QRTZ_TRIGGERS
(NEXT_FIRE_TIME)
/
CREATE INDEX IDX_QRTZ_T_NFT_ST
ON QRTZ_TRIGGERS
(NEXT_FIRE_TIME, TRIGGER_STATE)
/
CREATE INDEX IDX_QRTZ_T_STATE
ON QRTZ_TRIGGERS
(TRIGGER_STATE)
/
CREATE INDEX IDX_QRTZ_T_VOLATILE
ON QRTZ_TRIGGERS
(IS_VOLATILE)
/
-----------------------------------------------------------------------------
-- QRTZ_TRIGGER_LISTENERS
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'QRTZ_TRIGGER_LISTENERS';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE QRTZ_TRIGGER_LISTENERS CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE QRTZ_TRIGGER_LISTENERS
(
TRIGGER_NAME VARCHAR2(80)
, TRIGGER_GROUP VARCHAR2(80)
, TRIGGER_LISTENER VARCHAR2(80)
)
/
ALTER TABLE QRTZ_TRIGGER_LISTENERS
ADD CONSTRAINT QRTZ_TRIGGER_LISTENERSP1
PRIMARY KEY (TRIGGER_NAME,TRIGGER_GROUP,TRIGGER_LISTENER)
/
-----------------------------------------------------------------------------
-- SEC_SCRTY_ATTR_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'SEC_SCRTY_ATTR_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE SEC_SCRTY_ATTR_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE SEC_SCRTY_ATTR_T
(
ATTR_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ATTR_NM VARCHAR2(100) NOT NULL
, ACTV_IND CHAR(1) default 'Y' NOT NULL
, CONSTRAINT SEC_SCRTY_ATTR_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE SEC_SCRTY_ATTR_T
ADD CONSTRAINT SEC_SCRTY_ATTR_TP1
PRIMARY KEY (ATTR_ID)
/
-----------------------------------------------------------------------------
-- SEC_SCRTY_DEFN_DOC_TYP_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'SEC_SCRTY_DEFN_DOC_TYP_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE SEC_SCRTY_DEFN_DOC_TYP_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE SEC_SCRTY_DEFN_DOC_TYP_T
(
DEFN_ID NUMBER(10)
, DOC_TYP_NM VARCHAR2(64)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ACTV_IND CHAR(1) default 'Y' NOT NULL
, CONSTRAINT SEC_SCRTY_DEFN_DOC_TYP_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE SEC_SCRTY_DEFN_DOC_TYP_T
ADD CONSTRAINT SEC_SCRTY_DEFN_DOC_TYP_TP1
PRIMARY KEY (DEFN_ID,DOC_TYP_NM)
/
-----------------------------------------------------------------------------
-- SEC_SCRTY_DEFN_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'SEC_SCRTY_DEFN_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE SEC_SCRTY_DEFN_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE SEC_SCRTY_DEFN_T
(
DEFN_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, DEFN_NM VARCHAR2(100) NOT NULL
, DEFN_DESC_TXT VARCHAR2(400)
, ROLE_ID VARCHAR2(40)
, ATTR_ID NUMBER(10) NOT NULL
, RSTR_VIEW_ACCT_LINE_IND CHAR(1) default 'N' NOT NULL
, RSTR_EDIT_ACCT_LINE_IND CHAR(1) default 'N' NOT NULL
, RSTR_VIEW_DOC_IND CHAR(1) default 'N' NOT NULL
, RSTR_EDIT_DOC_IND CHAR(1) default 'N' NOT NULL
, RSTR_VIEW_NTE_ATT_IND CHAR(1) default 'N' NOT NULL
, RSTR_LU_IND CHAR(1) default 'N' NOT NULL
, RSTR_GL_INQ_IND CHAR(1) default 'N' NOT NULL
, RSTR_LD_INQ_IND CHAR(1) default 'N' NOT NULL
, ACTV_IND CHAR(1) default 'Y' NOT NULL
, CONSTRAINT SEC_SCRTY_DEFN_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE SEC_SCRTY_DEFN_T
ADD CONSTRAINT SEC_SCRTY_DEFN_TP1
PRIMARY KEY (DEFN_ID)
/
-----------------------------------------------------------------------------
-- SEC_SCRTY_MDL_DEFN_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'SEC_SCRTY_MDL_DEFN_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE SEC_SCRTY_MDL_DEFN_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE SEC_SCRTY_MDL_DEFN_T
(
MDL_DEFN_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, MDL_ID NUMBER(10) NOT NULL
, DEFN_ID NUMBER(10) NOT NULL
, CONS_CD VARCHAR2(1) default 'A' NOT NULL
, OPR_CD VARCHAR2(2) NOT NULL
, ATTR_VAL VARCHAR2(400) NOT NULL
, OVRD_DNY_IND CHAR(1) default 'N' NOT NULL
, ACTV_IND CHAR(1) default 'Y' NOT NULL
, CONSTRAINT SEC_SCRTY_MDL_DEFN_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE SEC_SCRTY_MDL_DEFN_T
ADD CONSTRAINT SEC_SCRTY_MDL_DEFN_TP1
PRIMARY KEY (MDL_DEFN_ID)
/
-----------------------------------------------------------------------------
-- SEC_SCRTY_MDL_MBR_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'SEC_SCRTY_MDL_MBR_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE SEC_SCRTY_MDL_MBR_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE SEC_SCRTY_MDL_MBR_T
(
MDL_ID NUMBER(10)
, MBR_ID VARCHAR2(40)
, MBR_TYP_CD CHAR(1)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ACTV_FRM_DT DATE
, ACTV_TO_DT DATE
, CONSTRAINT SEC_SCRTY_MDL_MBR_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE SEC_SCRTY_MDL_MBR_T
ADD CONSTRAINT SEC_SCRTY_MDL_MBR_TP1
PRIMARY KEY (MDL_ID,MBR_ID,MBR_TYP_CD)
/
-----------------------------------------------------------------------------
-- SEC_SCRTY_MDL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'SEC_SCRTY_MDL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE SEC_SCRTY_MDL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE SEC_SCRTY_MDL_T
(
MDL_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, MDL_NM VARCHAR2(100) NOT NULL
, MDL_DESC_TXT VARCHAR2(400)
, ROLE_ID VARCHAR2(40)
, ACTV_IND CHAR(1) default 'Y' NOT NULL
, CONSTRAINT SEC_SCRTY_MDL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE SEC_SCRTY_MDL_T
ADD CONSTRAINT SEC_SCRTY_MDL_TP1
PRIMARY KEY (MDL_ID)
/
-----------------------------------------------------------------------------
-- SEC_SCRTY_PRNCPL_DEFN_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'SEC_SCRTY_PRNCPL_DEFN_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE SEC_SCRTY_PRNCPL_DEFN_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE SEC_SCRTY_PRNCPL_DEFN_T
(
PRNCPL_DEFN_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, DEFN_ID NUMBER(10) NOT NULL
, PRNCPL_ID VARCHAR2(40) NOT NULL
, CONS_CD VARCHAR2(1) default 'A' NOT NULL
, OPR_CD VARCHAR2(2) NOT NULL
, ATTR_VAL VARCHAR2(400) NOT NULL
, OVRD_DNY_IND CHAR(1) default 'N' NOT NULL
, ACTV_IND CHAR(1) default 'Y' NOT NULL
, CONSTRAINT SEC_SCRTY_PRNCPL_DEFN_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE SEC_SCRTY_PRNCPL_DEFN_T
ADD CONSTRAINT SEC_SCRTY_PRNCPL_DEFN_TP1
PRIMARY KEY (PRNCPL_DEFN_ID)
/
-----------------------------------------------------------------------------
-- SEC_SCRTY_PRNCPL_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'SEC_SCRTY_PRNCPL_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE SEC_SCRTY_PRNCPL_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE SEC_SCRTY_PRNCPL_T
(
PRNCPL_ID VARCHAR2(40)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ACTV_IND CHAR(1) default 'Y' NOT NULL
, CONSTRAINT SEC_SCRTY_PRNCPL_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE SEC_SCRTY_PRNCPL_T
ADD CONSTRAINT SEC_SCRTY_PRNCPL_TP1
PRIMARY KEY (PRNCPL_ID)
/
-----------------------------------------------------------------------------
-- SH_ACCT_PERIOD_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'SH_ACCT_PERIOD_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE SH_ACCT_PERIOD_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE SH_ACCT_PERIOD_T
(
UNIV_FISCAL_YR NUMBER(4)
, UNIV_FISCAL_PRD_CD VARCHAR2(2)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, UNIV_FISCAL_PRD_NM VARCHAR2(10)
, ROW_ACTV_IND VARCHAR2(1)
, BDGT_ROLLOVER_CD VARCHAR2(1)
, UNIV_FSCPD_END_DT DATE
, CONSTRAINT SH_ACCT_PERIOD_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE SH_ACCT_PERIOD_T
ADD CONSTRAINT SH_ACCT_PERIOD_TP1
PRIMARY KEY (UNIV_FISCAL_YR,UNIV_FISCAL_PRD_CD)
/
-----------------------------------------------------------------------------
-- SH_BUILDING_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'SH_BUILDING_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE SH_BUILDING_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE SH_BUILDING_T
(
CAMPUS_CD VARCHAR2(2)
, BLDG_CD VARCHAR2(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, BLDG_NM VARCHAR2(40)
, BLDG_STR_ADDR VARCHAR2(40)
, BLDG_ADDR_CTY_NM VARCHAR2(37)
, BLDG_ADDR_ST_CD VARCHAR2(2)
, BLDG_ADDR_ZIP_CD VARCHAR2(20)
, ALTRNT_BLDG_CD VARCHAR2(4)
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, BLDG_ADDR_CNTRY_CD VARCHAR2(2)
, CONSTRAINT SH_BUILDING_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE SH_BUILDING_T
ADD CONSTRAINT SH_BUILDING_TP1
PRIMARY KEY (CAMPUS_CD,BLDG_CD)
/
-----------------------------------------------------------------------------
-- SH_FNCTNL_FIELD_DESCR_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'SH_FNCTNL_FIELD_DESCR_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE SH_FNCTNL_FIELD_DESCR_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE SH_FNCTNL_FIELD_DESCR_T
(
NMSPC_CD VARCHAR2(20)
, CMPNT_CLSS VARCHAR2(100)
, PRPRTY_NM VARCHAR2(100)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, FNCTNL_FIELD_DESCR VARCHAR2(4000)
, ACTIVE_IND VARCHAR2(1)
, CONSTRAINT SH_FNCTNL_FIELD_DESCR_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE SH_FNCTNL_FIELD_DESCR_T
ADD CONSTRAINT SH_FNCTNL_FIELD_DESCR_TP1
PRIMARY KEY (NMSPC_CD,CMPNT_CLSS,PRPRTY_NM)
/
-----------------------------------------------------------------------------
-- SH_ROOM_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'SH_ROOM_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE SH_ROOM_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE SH_ROOM_T
(
CAMPUS_CD VARCHAR2(2)
, BLDG_CD VARCHAR2(10)
, BLDG_ROOM_NBR VARCHAR2(8)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, BLDG_ROOM_TYPE VARCHAR2(50)
, BLDG_ROOM_DEPT VARCHAR2(40)
, BLDG_ROOM_DESC VARCHAR2(25)
, ROW_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT SH_ROOM_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE SH_ROOM_T
ADD CONSTRAINT SH_ROOM_TP1
PRIMARY KEY (CAMPUS_CD,BLDG_CD,BLDG_ROOM_NBR)
/
-----------------------------------------------------------------------------
-- SH_UNIV_DATE_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'SH_UNIV_DATE_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE SH_UNIV_DATE_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE SH_UNIV_DATE_T
(
UNIV_DT DATE
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, UNIV_FISCAL_YR NUMBER(4)
, UNIV_FISCAL_PRD_CD VARCHAR2(2)
, CONSTRAINT SH_UNIV_DATE_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE SH_UNIV_DATE_T
ADD CONSTRAINT SH_UNIV_DATE_TP1
PRIMARY KEY (UNIV_DT)
/
CREATE INDEX SH_UNIV_DATE_TI2
ON SH_UNIV_DATE_T
(UNIV_FISCAL_YR)
/
-----------------------------------------------------------------------------
-- SH_UOM_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'SH_UOM_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE SH_UOM_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE SH_UOM_T
(
ITM_UOM_CD VARCHAR2(4)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, ITM_UOM_DESC VARCHAR2(45)
, DOBJ_MAINT_CD_ACTV_IND VARCHAR2(1) NOT NULL
, CONSTRAINT PUR_AP_UOM_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE SH_UOM_T
ADD CONSTRAINT SH_UOM_TP1
PRIMARY KEY (ITM_UOM_CD)
/
-----------------------------------------------------------------------------
-- OLE_AP_INV_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_AP_INV_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_AP_INV_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_AP_INV_T
(
INV_RQST_ID NUMBER(9)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, INV_STAT_CD VARCHAR2(4)
, FDOC_NBR VARCHAR2(14) NOT NULL
, INV_DT DATE NOT NULL
, INV_NBR VARCHAR2(25)
, VNDR_INV_AMT NUMBER(19,2)
, VNDR_FRGN_INV_AMT NUMBER(19,2)
, VNDR_PMT_TERMS_CD VARCHAR2(5)
, VNDR_SHP_PMT_TERM_CD VARCHAR2(4)
, VNDR_CUST_NBR VARCHAR2(30)
, AP_PUR_DOC_LNK_ID NUMBER(10)
, INV_PAY_DT DATE
, PMT_HLD_IND VARCHAR2(1)
, INV_CNCL_IND VARCHAR2(1)
, PMT_ATT_IND VARCHAR2(1)
, IMD_PMT_IND VARCHAR2(1)
, INV_HLD_IND VARCHAR2(1)
, INV_NTE_LN1_TXT VARCHAR2(90)
, INV_NTE_LN2_TXT VARCHAR2(90)
, INV_NTE_LN3_TXT VARCHAR2(90)
, INV_SPCL_HANDLG_INSTRC_LN1_TXT VARCHAR2(90)
, INV_SPCL_HANDLG_INSTRC_LN2_TXT VARCHAR2(90)
, INV_SPCL_HANDLG_INSTRC_LN3_TXT VARCHAR2(90)
, INV_PD_DT DATE
, INV_ELCTRNC_INV_IND VARCHAR2(1)
, VNDR_HDR_GNRTD_ID NUMBER(10)
, VNDR_DTL_ASND_ID NUMBER(10)
, VNDR_NM VARCHAR2(45)
, VNDR_LN1_ADDR VARCHAR2(45)
, VNDR_LN2_ADDR VARCHAR2(45)
, VNDR_CTY_NM VARCHAR2(45)
, VNDR_ST_CD VARCHAR2(2)
, VNDR_PSTL_CD VARCHAR2(20)
, VNDR_CNTRY_CD VARCHAR2(2)
, PMT_EXTRT_DT DATE
, AP_PRCSR_ID VARCHAR2(40) NOT NULL
, AP_RQST_CNCL_ID VARCHAR2(40)
, AP_HLD_ID VARCHAR2(40)
, PRCS_CMP_CD VARCHAR2(2)
, AP_APRVL_DT DATE
, ORIG_VNDR_HDR_GNRTD_ID NUMBER(10)
, ORIG_VNDR_DTL_ASND_ID NUMBER(10)
, ALTRNT_VNDR_HDR_GNRTD_ID NUMBER(10)
, ALTRNT_VNDR_DTL_ASND_ID NUMBER(10)
, CONT_ACCT_IND VARCHAR2(1)
, VNDR_ADDR_INTL_PROV_NM VARCHAR2(45)
, INV_PSTV_APRVL_IND VARCHAR2(1)
, USE_TAX_IND VARCHAR2(1) default 'Y' NOT NULL
, BNK_CD VARCHAR2(4)
, TAX_CLSIF_CD VARCHAR2(50)
, FTX_PCT NUMBER(10,8)
, STX_PCT NUMBER(10,8)
, TAX_CNTRY_CD VARCHAR2(10)
, GRS_UP_IND VARCHAR2(1)
, TRTY_EXMPT_IND VARCHAR2(1)
, FRGN_SRC_IND VARCHAR2(1)
, SPCL_W4_INC_AMT NUMBER(19,2)
, USAID_DIEM_IND VARCHAR2(1)
, INC_TAX_EXMPT_CD_OTHR_IND VARCHAR2(1)
, NQI_CUST_TAX_ID VARCHAR2(50)
, VNDR_ATTN_NM VARCHAR2(45)
, OLE_VNDR_CURR_ID NUMBER(10)
, OLE_VNDR_FOR_CURR_INV_AMT NUMBER(19,2)
, OLE_INV_TYP_ID NUMBER(10)
, OLE_INV_SUB_TYP_ID NUMBER(10)
, OLE_PMT_MTHD_ID NUMBER(10)
, OLE_CURR_TYP_ID NUMBER(8)
, OLE_VNDR_PO_ID VARCHAR2(100)
, ACCT_DISTR_MTD_IND VARCHAR2(1) default 'P' NOT NULL
, OLE_PR_BY VARCHAR2(50)
, OLE_PRFRMA_IND VARCHAR2(1)
, OLE_EXCHNG_RATE VARCHAR2(10)
, CONSTRAINT OLE_AP_INV_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE OLE_AP_INV_T
ADD CONSTRAINT OLE_AP_INV_TP1
PRIMARY KEY (INV_RQST_ID)
/
CREATE INDEX OLE_AP_INV_TI3
ON OLE_AP_INV_T
(FDOC_NBR)
/
CREATE INDEX OLE_AP_INV_TI4
ON OLE_AP_INV_T
(AP_PUR_DOC_LNK_ID)
/
-----------------------------------------------------------------------------
-- OLE_AP_INV_PO_ITM_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_AP_INV_PO_ITM_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_AP_INV_PO_ITM_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_AP_INV_PO_ITM_T
(
INV_PO_ITM_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, PO_ID NUMBER(9)
, PO_LN_NBR NUMBER(3)
, PO_ENCUM_FSCL_YR NUMBER(4) NOT NULL
, PO_CLSIF_TYP_DESC VARCHAR2(4)
, INV_RQST_ID NUMBER(9) NOT NULL
, AP_PUR_DOC_LNK_ID NUMBER(10)
, ITM_LN_NBR NUMBER(3)
, ITM_TYP_CD VARCHAR2(4)
, ITM_DESC VARCHAR2(4000)
, ITM_CATLG_NBR VARCHAR2(30)
, ITM_AUX_PART_ID VARCHAR2(300)
, ITM_UOM_CD VARCHAR2(4)
, ITM_INV_QTY NUMBER(11,2)
, ITM_UNIT_PRC NUMBER(19,4)
, PO_ITM_UNIT_PRC NUMBER(19,4)
, CLOSE_PO_IND VARCHAR2(1)
, REOPEN_PO_IND VARCHAR2(1)
, RCVNG_DOC_REQ_IND VARCHAR2(1)
, CPTL_AST_TRN_TYP_CD VARCHAR2(4)
, ITM_CPTL_AST_NTE_TXT VARCHAR2(800)
, ITM_ASND_TO_TRADE_IN_IND VARCHAR2(1)
, ITM_OSTND_INV_QTY NUMBER(11,2)
, ITM_OSTND_INV_AMT NUMBER(19,2)
, ITM_TAX_AMT NUMBER(19,4)
, ITM_EXTND_PRC NUMBER(19,2)
, OLE_ITM_OSTND_INV_PRTS NUMBER(11,2)
, OLE_ITM_INV_PRTS NUMBER(11,2)
, OLE_DISCNT NUMBER(19,4)
, OLE_DISCNT_TYP VARCHAR2(1)
, OLE_FOR_DISCNT_TYP VARCHAR2(1)
, OLE_FOR_DISCNT NUMBER(19,4)
, OLE_FOR_LST_PRC NUMBER(19,4)
, OLE_FOR_DISCNT_AMT NUMBER(19,4)
, OLE_FOR_UNT_CST NUMBER(19,4)
, OLE_EXCHANGE_RT NUMBER(19,6)
, OLE_CON_CST NUMBER(19,4)
, OLE_PR_QTY VARCHAR2(1)
, OLE_PR_AMT VARCHAR2(1)
, OLE_PR_MAN VARCHAR2(1)
, OLE_FRMT_ID NUMBER(8)
, OLE_VNDR_IT_ID VARCHAR2(100)
, OLE_PO_ITM_ID NUMBER(10)
, OLE_LST_PRC NUMBER(19,4)
, OLE_DOCUMENT_UUID VARCHAR2(50)
, SUB_FROM_DT DATE
, SUB_TO_DT DATE
, SUB_OVERLAP VARCHAR2(1)
, USE_TAX_IND VARCHAR2(1) default 'Y' NOT NULL
, OLE_ADDL_CHRG_USD VARCHAR2(1) default 'N' NOT NULL
, OLE_REQ_RCPT_STATUS_ID NUMBER(10)
, OLE_ITM_PO_END_DT DATE
, OLE_DEBIT_ITM VARCHAR2(1) default 'Y'
, CONSTRAINT OLE_AP_INV_PO_ITM_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE OLE_AP_INV_PO_ITM_T
ADD CONSTRAINT OLE_AP_INV_PO_ITM_TP1
PRIMARY KEY (INV_PO_ITM_ID)
/
CREATE INDEX OLE_AP_INV_PO_ITM_TI1
ON OLE_AP_INV_PO_ITM_T
(INV_RQST_ID)
/
CREATE INDEX OLE_AP_INV_PO_ITM_TI4
ON OLE_AP_INV_PO_ITM_T
(AP_PUR_DOC_LNK_ID)
/
-----------------------------------------------------------------------------
-- OLE_AP_INV_ACCT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_AP_INV_ACCT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_AP_INV_ACCT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_AP_INV_ACCT_T
(
INV_ACCT_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, INV_PO_ITM_ID NUMBER(10)
, FIN_COA_CD VARCHAR2(2) NOT NULL
, ACCOUNT_NBR VARCHAR2(7) NOT NULL
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, FIN_OBJECT_CD VARCHAR2(4) NOT NULL
, PROJECT_CD VARCHAR2(10)
, ORG_REFERENCE_ID VARCHAR2(8)
, ITM_ACCT_TOT_AMT NUMBER(19,2) NOT NULL
, ACLN_PCT NUMBER(35,20) NOT NULL
, DISENC_AMT NUMBER(19,2) NOT NULL
, FDOC_LINE_NBR NUMBER(7)
, CONSTRAINT OLE_AP_INV_ACCT_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE OLE_AP_INV_ACCT_T
ADD CONSTRAINT OLE_AP_INV_ACCT_TP1
PRIMARY KEY (INV_ACCT_ID)
/
CREATE INDEX OLE_AP_INV_ACCT_TI1
ON OLE_AP_INV_ACCT_T
(INV_PO_ITM_ID)
/
CREATE INDEX OLE_AP_INV_ACCT_TI2
ON OLE_AP_INV_ACCT_T
(FIN_COA_CD)
/
CREATE INDEX OLE_AP_INV_ACCT_TI3
ON OLE_AP_INV_ACCT_T
(FIN_COA_CD, ACCOUNT_NBR)
/
CREATE INDEX OLE_AP_INV_ACCT_TI4
ON OLE_AP_INV_ACCT_T
(FIN_COA_CD, ACCOUNT_NBR, SUB_ACCT_NBR)
/
-----------------------------------------------------------------------------
-- OLE_AP_INV_SUM_ACCT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_AP_INV_SUM_ACCT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_AP_INV_SUM_ACCT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_AP_INV_SUM_ACCT_T
(
INV_SUM_ACCT_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, INV_RQST_ID NUMBER(9)
, FIN_COA_CD VARCHAR2(2) NOT NULL
, ACCOUNT_NBR VARCHAR2(7) NOT NULL
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_SUB_OBJ_CD VARCHAR2(3)
, FIN_OBJECT_CD VARCHAR2(4) NOT NULL
, PROJECT_CD VARCHAR2(10)
, ORG_REFERENCE_ID VARCHAR2(8)
, ITM_ACCT_TOT_AMT NUMBER(19,2) NOT NULL
, CRDT_MEMO_ID NUMBER(9)
, LST_UPDT_TS DATE
, CONSTRAINT OLE_AP_INV_SUM_ACCT_TI1 UNIQUE (INV_RQST_ID, FIN_COA_CD, ACCOUNT_NBR, SUB_ACCT_NBR, FIN_SUB_OBJ_CD, FIN_OBJECT_CD, PROJECT_CD, ORG_REFERENCE_ID)
, CONSTRAINT OLE_AP_INV_SUM_ACCT_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE OLE_AP_INV_SUM_ACCT_T
ADD CONSTRAINT OLE_AP_INV_SUM_ACCT_TP1
PRIMARY KEY (INV_SUM_ACCT_ID)
/
-----------------------------------------------------------------------------
-- OLE_AP_INV_ACCT_CHG_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_AP_INV_ACCT_CHG_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_AP_INV_ACCT_CHG_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_AP_INV_ACCT_CHG_T
(
INV_ACCT_CHG_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, INV_PO_ITM_ID NUMBER(10)
, FIN_COA_CD VARCHAR2(2) NOT NULL
, ACCOUNT_NBR VARCHAR2(7) NOT NULL
, SUB_ACCT_NBR VARCHAR2(5)
, FIN_OBJECT_CD VARCHAR2(4) NOT NULL
, FIN_SUB_OBJ_CD VARCHAR2(3)
, PROJECT_CD VARCHAR2(10)
, ORG_REFERENCE_ID VARCHAR2(8)
, ITM_ACCT_TOT_AMT NUMBER(19,2) NOT NULL
, ACLN_PCT NUMBER(35,20)
, INV_ACCT_CHG_TS DATE NOT NULL
, FDOC_POST_YR NUMBER(4)
, FDOC_POST_PRD_CD VARCHAR2(2)
, OLE_DISENC_AMT NUMBER(19,2) NOT NULL
, CONSTRAINT OLE_AP_INV_ACCT_CHG_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE OLE_AP_INV_ACCT_CHG_T
ADD CONSTRAINT OLE_AP_INV_ACCT_CHG_TP1
PRIMARY KEY (INV_ACCT_CHG_ID)
/
CREATE INDEX OLE_AP_INV_ACCT_CHG_TI1
ON OLE_AP_INV_ACCT_CHG_T
(INV_ACCT_CHG_TS)
/
CREATE INDEX OLE_AP_INV_ACCT_CHG_TI2
ON OLE_AP_INV_ACCT_CHG_T
(INV_PO_ITM_ID)
/
-----------------------------------------------------------------------------
-- OLE_AP_INV_PO_ITM_USE_TAX_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_AP_INV_PO_ITM_USE_TAX_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_AP_INV_PO_ITM_USE_TAX_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_AP_INV_PO_ITM_USE_TAX_T
(
INV_PO_ITM_USE_TAX_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, INV_PO_ITM_ID NUMBER(10)
, RATE_CD VARCHAR2(10) NOT NULL
, TAX_AMT NUMBER(19,4)
, FIN_COA_CD VARCHAR2(2) NOT NULL
, ACCOUNT_NBR VARCHAR2(7) NOT NULL
, FIN_OBJECT_CD VARCHAR2(4) NOT NULL
, CONSTRAINT OLE_AP_INV_PO_ITM_USE_TAX_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE OLE_AP_INV_PO_ITM_USE_TAX_T
ADD CONSTRAINT OLE_AP_INV_PO_ITM_USE_TAX_TP1
PRIMARY KEY (INV_PO_ITM_USE_TAX_ID)
/
-----------------------------------------------------------------------------
-- OLE_AP_INV_ITM_NTE_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_AP_INV_ITM_NTE_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_AP_INV_ITM_NTE_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_AP_INV_ITM_NTE_T
(
OLE_INV_ITM_NTE_ID NUMBER(10)
, INV_PO_ITM_ID NUMBER(10)
, OLE_NTE VARCHAR2(2000) NOT NULL
, VER_NBR NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
)
/
ALTER TABLE OLE_AP_INV_ITM_NTE_T
ADD CONSTRAINT OLE_AP_INV_ITM_NTE_TP1
PRIMARY KEY (OLE_INV_ITM_NTE_ID,INV_PO_ITM_ID)
/
-----------------------------------------------------------------------------
-- OLE_COPY_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_COPY_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_COPY_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_COPY_T
(
OLE_COPY_ID VARCHAR2(40)
, REQS_ID NUMBER(8)
, REQS_ITM_ID NUMBER(10)
, FDOC_NBR VARCHAR2(14)
, PO_ITM_ID NUMBER(10)
, RCVNG_LN_ITM_ID NUMBER(10)
, RCVNG_COR_ITM_ID NUMBER(10)
, ITEM_UUID VARCHAR2(100)
, E_RES_REC_ID VARCHAR2(40)
, SER_RCV_ID VARCHAR2(40)
, INSTANCE_UUID VARCHAR2(100)
, BIB_UUID VARCHAR2(100)
, LOC VARCHAR2(40)
, COPY_NUM VARCHAR2(40)
, PART_NUM VARCHAR2(40)
, ENUM VARCHAR2(40)
, RCPT_STAT VARCHAR2(40)
, VER_NBR NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
)
/
ALTER TABLE OLE_COPY_T
ADD CONSTRAINT OLE_COPY_TP1
PRIMARY KEY (OLE_COPY_ID)
/
-----------------------------------------------------------------------------
-- OLE_LINK_PURAP_DONOR_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_LINK_PURAP_DONOR_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_LINK_PURAP_DONOR_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_LINK_PURAP_DONOR_T
(
LINK_PURAP_DONOR_ID NUMBER(38)
, REQ_ITEM_ID NUMBER(8)
, FDOC_NBR VARCHAR2(14)
, PO_ITM_ID NUMBER(8)
, RCVNG_LN_ITM_ID NUMBER(8)
, RCVNG_COR_ITM_ID NUMBER(8)
, DONOR_ID VARCHAR2(10)
, DONOR_CODE VARCHAR2(10)
, VER_NBR NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
)
/
ALTER TABLE OLE_LINK_PURAP_DONOR_T
ADD CONSTRAINT OLE_LINK_PURAP_DONOR_TP1
PRIMARY KEY (LINK_PURAP_DONOR_ID)
/
CREATE INDEX OLE_LINK_PURAP_DONOR_TI1
ON OLE_LINK_PURAP_DONOR_T
(REQ_ITEM_ID)
/
CREATE INDEX OLE_LINK_PURAP_DONOR_TI2
ON OLE_LINK_PURAP_DONOR_T
(FDOC_NBR)
/
CREATE INDEX OLE_LINK_PURAP_DONOR_TI3
ON OLE_LINK_PURAP_DONOR_T
(PO_ITM_ID)
/
CREATE INDEX OLE_LINK_PURAP_DONOR_TI4
ON OLE_LINK_PURAP_DONOR_T
(RCVNG_LN_ITM_ID)
/
CREATE INDEX OLE_LINK_PURAP_DONOR_TI5
ON OLE_LINK_PURAP_DONOR_T
(RCVNG_COR_ITM_ID)
/
CREATE INDEX OLE_LINK_PURAP_DONOR_TI6
ON OLE_LINK_PURAP_DONOR_T
(DONOR_ID)
/
-----------------------------------------------------------------------------
-- OLE_PAID_COPY_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_PAID_COPY_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_PAID_COPY_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_PAID_COPY_T
(
OLE_PAID_COPY_ID VARCHAR2(40)
, OLE_COPY_ID VARCHAR2(40)
, INV_PO_ITM_ID NUMBER(10)
, INV_RQST_ID NUMBER(9)
, PMT_RQST_ITM_ID NUMBER(10)
, PMT_RQST_ID NUMBER(9)
, VER_NBR NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
)
/
ALTER TABLE OLE_PAID_COPY_T
ADD CONSTRAINT OLE_PAID_COPY_TP1
PRIMARY KEY (OLE_PAID_COPY_ID)
/
-----------------------------------------------------------------------------
-- OLE_INV_ING_DET_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_INV_ING_DET_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_INV_ING_DET_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_INV_ING_DET_T
(
LOAD_ID NUMBER(10)
, VENDOR VARCHAR2(36)
, FILE_NAME VARCHAR2(36)
, UPLOADED_DATE DATE
, VER_NBR NUMBER(8) NOT NULL
, OBJ_ID VARCHAR2(36) NOT NULL
)
/
ALTER TABLE OLE_INV_ING_DET_T
ADD CONSTRAINT OLE_INV_ING_DET_TP1
PRIMARY KEY (LOAD_ID)
/
-----------------------------------------------------------------------------
-- OLE_AP_INV_OFFSET_ACCT_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_AP_INV_OFFSET_ACCT_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_AP_INV_OFFSET_ACCT_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_AP_INV_OFFSET_ACCT_T
(
INV_OFF_ACCT_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) default 1 NOT NULL
, INV_PO_ITM_ID NUMBER(10)
, FIN_COA_CD VARCHAR2(2) NOT NULL
, OFF_ACCOUNT_NBR VARCHAR2(7) NOT NULL
, OFF_SUB_ACCT_NBR VARCHAR2(5)
, OFF_FIN_SUB_OBJ_CD VARCHAR2(3)
, OFF_FIN_OBJECT_CD VARCHAR2(4) NOT NULL
, PROJECT_CD VARCHAR2(10)
, ORG_REFERENCE_ID VARCHAR2(8)
, ITM_ACCT_TOT_AMT NUMBER(19,2) NOT NULL
, ACLN_PCT NUMBER(35,20) NOT NULL
, DISENC_AMT NUMBER(19,2) NOT NULL
, FDOC_LINE_NBR NUMBER(7)
, CONSTRAINT OLE_AP_INV_OFF_ACCT_TC0 UNIQUE (OBJ_ID)
)
/
ALTER TABLE OLE_AP_INV_OFFSET_ACCT_T
ADD CONSTRAINT OLE_AP_INV_OFFSET_ACCT_TP1
PRIMARY KEY (INV_OFF_ACCT_ID)
/
CREATE INDEX OLE_AP_INV_OFF_ACCT_TI1
ON OLE_AP_INV_OFFSET_ACCT_T
(INV_PO_ITM_ID)
/
-----------------------------------------------------------------------------
-- OLE_PO_CLM_HIS_T
-----------------------------------------------------------------------------
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_tables WHERE table_name = 'OLE_PO_CLM_HIS_T';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP TABLE OLE_PO_CLM_HIS_T CASCADE CONSTRAINTS PURGE'; END IF;
END;
/
CREATE TABLE OLE_PO_CLM_HIS_T
(
OLE_PO_CLM_HIS_ID VARCHAR2(40)
, CLM_DT DATE
, OPTR_ID VARCHAR2(40)
, CLM_CNT NUMBER(8)
, CLM_RESP_INFO VARCHAR2(500)
, REQS_ITM_ID NUMBER(10)
, FDOC_NBR VARCHAR2(14)
, PO_ITM_ID NUMBER(10)
, OBJ_ID VARCHAR2(36) NOT NULL
, VER_NBR NUMBER(8) NOT NULL
)
/
ALTER TABLE OLE_PO_CLM_HIS_T
ADD CONSTRAINT OLE_PO_CLM_HIS_TP1
PRIMARY KEY (OLE_PO_CLM_HIS_ID)
/
-- -----------------------------------------------------------------------
-- CA_OBJECT_CODE_V
-- -----------------------------------------------------------------------
CREATE OR REPLACE FORCE VIEW CA_OBJECT_CODE_V AS
( SELECT C.UNIV_FISCAL_YR, FIN_COA_CD, FIN_OBJECT_CD, FIN_OBJ_CD_NM, FIN_OBJ_CD_SHRT_NM, FIN_OBJ_LEVEL_CD, RPTS_TO_FIN_COA_CD, RPTS_TO_FIN_OBJ_CD , FIN_OBJ_TYP_CD, FIN_OBJ_SUB_TYP_CD, HIST_FIN_OBJECT_CD, FIN_OBJ_ACTIVE_CD, FOBJ_BDGT_AGGR_CD, FOBJ_MNXFR_ELIM_CD, FIN_FED_FUNDED_CD, NXT_YR_FIN_OBJ_CD, RSCH_BDGT_CTGRY_CD, RSCH_OBJ_CD_DESC, RSCH_ON_CMP_IND FROM CA_OBJECT_CODE_T C, SH_UNIV_DATE_T S WHERE C.UNIV_FISCAL_YR = S.UNIV_FISCAL_YR AND UNIV_DT = TRUNC(SYSDATE) )
/
-- -----------------------------------------------------------------------
-- CA_SUB_OBJECT_CD_V
-- -----------------------------------------------------------------------
CREATE OR REPLACE FORCE VIEW CA_SUB_OBJECT_CD_V AS
( SELECT C.UNIV_FISCAL_YR, FIN_COA_CD, ACCOUNT_NBR, FIN_OBJECT_CD, FIN_SUB_OBJ_CD, FIN_SUB_OBJ_CD_NM, FIN_SUBOBJ_SHRT_NM, FIN_SUBOBJ_ACTV_CD FROM CA_SUB_OBJECT_CD_T C, SH_UNIV_DATE_T S WHERE C.UNIV_FISCAL_YR = S.UNIV_FISCAL_YR AND UNIV_DT = TRUNC(SYSDATE) )
/
-- -----------------------------------------------------------------------
-- PUR_PO_ITM_TOT_AMT_V
-- -----------------------------------------------------------------------
CREATE OR REPLACE FORCE VIEW PUR_PO_ITM_TOT_AMT_V AS
(select fdoc_nbr, sum(
CASE
WHEN ITM_ACTV_IND = 'Y' AND ITM_ORD_QTY IS NULL THEN ITM_UNIT_PRC
WHEN ITM_ACTV_IND = 'Y' AND ITM_ORD_QTY IS NOT NULL THEN ITM_ORD_QTY * ITM_UNIT_PRC
WHEN ITM_ACTV_IND IS NULL AND ITM_ORD_QTY IS NULL THEN ITM_UNIT_PRC
WHEN ITM_ACTV_IND IS NULL AND ITM_ORD_QTY IS NOT NULL THEN ITM_ORD_QTY * ITM_UNIT_PRC
WHEN ITM_ACTV_IND ='N' THEN 0
ELSE 0
END) as TOTAL_AMOUNT
from PUR_PO_ITM_T group by fdoc_nbr)
/
-- -----------------------------------------------------------------------
-- PUR_PO_ITM_TOT_ENC_V
-- -----------------------------------------------------------------------
CREATE OR REPLACE FORCE VIEW PUR_PO_ITM_TOT_ENC_V AS
(SELECT A.FDOC_NBR AS FDOC_NBR, SUM(A.ITM_OSTND_ENC_AMT) AS TOTAL_ENCUMBRANCE FROM PUR_PO_ITM_T A GROUP BY A.FDOC_NBR)
/
-- -----------------------------------------------------------------------
-- PUR_PO_V
-- -----------------------------------------------------------------------
CREATE OR REPLACE FORCE VIEW PUR_PO_V AS
SELECT P.AP_PUR_DOC_LNK_ID, P.PO_ID, P.PO_CUR_IND, P.FDOC_NBR, P.OBJ_ID, D.APP_DOC_STAT, P.RECUR_PMT_TYP_CD, P.PO_VNDR_CHC_CD, P.PO_END_DT, E.TOTAL_ENCUMBRANCE, SUMMATION.TOTAL_AMOUNT FROM PUR_PO_T P, KREW_DOC_HDR_T D, PUR_PO_ITM_TOT_ENC_V E, PUR_PO_ITM_TOT_AMT_V SUMMATION WHERE P.FDOC_NBR = E.FDOC_NBR AND P.FDOC_NBR=D.DOC_HDR_ID AND P.FDOC_NBR = SUMMATION.FDOC_NBR
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'AP_CRDT_MEMO_ACCT_CHG_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE AP_CRDT_MEMO_ACCT_CHG_SEQ'; END IF;
END;
/
CREATE SEQUENCE AP_CRDT_MEMO_ACCT_CHG_SEQ INCREMENT BY 1 START WITH 2000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'AP_CRDT_MEMO_ACCT_HIST_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE AP_CRDT_MEMO_ACCT_HIST_SEQ'; END IF;
END;
/
CREATE SEQUENCE AP_CRDT_MEMO_ACCT_HIST_SEQ INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'AP_CRDT_MEM_ITM_USE_TAX_ID_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE AP_CRDT_MEM_ITM_USE_TAX_ID_SEQ'; END IF;
END;
/
CREATE SEQUENCE AP_CRDT_MEM_ITM_USE_TAX_ID_SEQ INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'AP_ELCTRNC_INV_MAP_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE AP_ELCTRNC_INV_MAP_ID'; END IF;
END;
/
CREATE SEQUENCE AP_ELCTRNC_INV_MAP_ID INCREMENT BY 1 START WITH 1 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'AP_INV_RJT_ID_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE AP_INV_RJT_ID_SEQ'; END IF;
END;
/
CREATE SEQUENCE AP_INV_RJT_ID_SEQ INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'AP_NEG_PMT_RQST_APRVL_LMT_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE AP_NEG_PMT_RQST_APRVL_LMT_ID'; END IF;
END;
/
CREATE SEQUENCE AP_NEG_PMT_RQST_APRVL_LMT_ID INCREMENT BY 1 START WITH 1002 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'AP_PMT_RQST_ACCT_CHG_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE AP_PMT_RQST_ACCT_CHG_SEQ'; END IF;
END;
/
CREATE SEQUENCE AP_PMT_RQST_ACCT_CHG_SEQ INCREMENT BY 1 START WITH 2000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'AP_PMT_RQST_ACCT_HIST_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE AP_PMT_RQST_ACCT_HIST_SEQ'; END IF;
END;
/
CREATE SEQUENCE AP_PMT_RQST_ACCT_HIST_SEQ INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'AP_PMT_RQST_ITM_USE_TAX_ID_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE AP_PMT_RQST_ITM_USE_TAX_ID_SEQ'; END IF;
END;
/
CREATE SEQUENCE AP_PMT_RQST_ITM_USE_TAX_ID_SEQ INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'AP_PUR_DOC_LNK_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE AP_PUR_DOC_LNK_ID'; END IF;
END;
/
CREATE SEQUENCE AP_PUR_DOC_LNK_ID INCREMENT BY 1 START WITH 21 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'AP_SUM_ACCT_T_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE AP_SUM_ACCT_T_SEQ'; END IF;
END;
/
CREATE SEQUENCE AP_SUM_ACCT_T_SEQ INCREMENT BY 1 START WITH 1 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'CA_A21_ICR_ACCT_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE CA_A21_ICR_ACCT_SEQ'; END IF;
END;
/
CREATE SEQUENCE CA_A21_ICR_ACCT_SEQ INCREMENT BY 1 START WITH 10004 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'CA_ACCT_AUTODEF_ICR_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE CA_ACCT_AUTODEF_ICR_SEQ'; END IF;
END;
/
CREATE SEQUENCE CA_ACCT_AUTODEF_ICR_SEQ INCREMENT BY 1 START WITH 10000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'CA_ICR_ACCT_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE CA_ICR_ACCT_SEQ'; END IF;
END;
/
CREATE SEQUENCE CA_ICR_ACCT_SEQ INCREMENT BY 1 START WITH 12269 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'CGPRPSL_NBR_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE CGPRPSL_NBR_SEQ'; END IF;
END;
/
CREATE SEQUENCE CGPRPSL_NBR_SEQ INCREMENT BY 1 START WITH 80059 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'CG_AGENCY_NBR_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE CG_AGENCY_NBR_SEQ'; END IF;
END;
/
CREATE SEQUENCE CG_AGENCY_NBR_SEQ INCREMENT BY 1 START WITH 55061 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'CG_PRPSL_CLOSE_NBR_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE CG_PRPSL_CLOSE_NBR_SEQ'; END IF;
END;
/
CREATE SEQUENCE CG_PRPSL_CLOSE_NBR_SEQ INCREMENT BY 1 START WITH 2040 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'CG_SUBCNR_NBR_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE CG_SUBCNR_NBR_SEQ'; END IF;
END;
/
CREATE SEQUENCE CG_SUBCNR_NBR_SEQ INCREMENT BY 1 START WITH 2080 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'CPTLAST_NBR_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE CPTLAST_NBR_SEQ'; END IF;
END;
/
CREATE SEQUENCE CPTLAST_NBR_SEQ INCREMENT BY 1 START WITH 500000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'CRDT_MEMO_ACCT_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE CRDT_MEMO_ACCT_ID'; END IF;
END;
/
CREATE SEQUENCE CRDT_MEMO_ACCT_ID INCREMENT BY 1 START WITH 1002 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'CRDT_MEMO_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE CRDT_MEMO_ID'; END IF;
END;
/
CREATE SEQUENCE CRDT_MEMO_ID INCREMENT BY 1 START WITH 1003 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'CRDT_MEMO_ITM_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE CRDT_MEMO_ITM_ID'; END IF;
END;
/
CREATE SEQUENCE CRDT_MEMO_ITM_ID INCREMENT BY 1 START WITH 1004 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'CRDT_MEMO_STAT_HIST_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE CRDT_MEMO_STAT_HIST_ID'; END IF;
END;
/
CREATE SEQUENCE CRDT_MEMO_STAT_HIST_ID INCREMENT BY 1 START WITH 1002 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'CUST_ADDR_ID_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE CUST_ADDR_ID_SEQ'; END IF;
END;
/
CREATE SEQUENCE CUST_ADDR_ID_SEQ INCREMENT BY 1 START WITH 2000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'CUST_NBR_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE CUST_NBR_SEQ'; END IF;
END;
/
CREATE SEQUENCE CUST_NBR_SEQ INCREMENT BY 1 START WITH 2000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'DIRTY_CACHE_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE DIRTY_CACHE_SEQ'; END IF;
END;
/
CREATE SEQUENCE DIRTY_CACHE_SEQ INCREMENT BY 1 START WITH 2000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'DV_PAYEE_ID_NBR_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE DV_PAYEE_ID_NBR_SEQ'; END IF;
END;
/
CREATE SEQUENCE DV_PAYEE_ID_NBR_SEQ INCREMENT BY 1 START WITH 178184 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'EN_SERVICE_DEF_INTERFACE_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE EN_SERVICE_DEF_INTERFACE_SEQ'; END IF;
END;
/
CREATE SEQUENCE EN_SERVICE_DEF_INTERFACE_SEQ INCREMENT BY 1 START WITH 2000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'FP_CASHIER_ITM_IN_PROC_T_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE FP_CASHIER_ITM_IN_PROC_T_SEQ'; END IF;
END;
/
CREATE SEQUENCE FP_CASHIER_ITM_IN_PROC_T_SEQ INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'FP_PRCRMNT_CARD_TRN_MT_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE FP_PRCRMNT_CARD_TRN_MT_SEQ'; END IF;
END;
/
CREATE SEQUENCE FP_PRCRMNT_CARD_TRN_MT_SEQ INCREMENT BY 1 START WITH 1000000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'GL_ORIGIN_ENTRY_GRP_T_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE GL_ORIGIN_ENTRY_GRP_T_SEQ'; END IF;
END;
/
CREATE SEQUENCE GL_ORIGIN_ENTRY_GRP_T_SEQ INCREMENT BY 1 START WITH 12069 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'GL_ORIGIN_ENTRY_T_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE GL_ORIGIN_ENTRY_T_SEQ'; END IF;
END;
/
CREATE SEQUENCE GL_ORIGIN_ENTRY_T_SEQ INCREMENT BY 1 START WITH 31905 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'INV_LOAD_SUM_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE INV_LOAD_SUM_ID'; END IF;
END;
/
CREATE SEQUENCE INV_LOAD_SUM_ID INCREMENT BY 1 START WITH 1002 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'INV_RJT_ITM_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE INV_RJT_ITM_ID'; END IF;
END;
/
CREATE SEQUENCE INV_RJT_ITM_ID INCREMENT BY 1 START WITH 1002 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'INV_RJT_REAS_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE INV_RJT_REAS_ID'; END IF;
END;
/
CREATE SEQUENCE INV_RJT_REAS_ID INCREMENT BY 1 START WITH 1002 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_ALIAS_TYP_ID_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_ALIAS_TYP_ID_S'; END IF;
END;
/
CREATE SEQUENCE OLE_ALIAS_TYP_ID_S INCREMENT BY 1 START WITH 1 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_CAT_ACCS_MTHD_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_CAT_ACCS_MTHD_S'; END IF;
END;
/
CREATE SEQUENCE OLE_CAT_ACCS_MTHD_S INCREMENT BY 1 START WITH 21 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_CAT_ACQ_MTHD_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_CAT_ACQ_MTHD_S'; END IF;
END;
/
CREATE SEQUENCE OLE_CAT_ACQ_MTHD_S INCREMENT BY 1 START WITH 21 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_CAT_ACTION_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_CAT_ACTION_S'; END IF;
END;
/
CREATE SEQUENCE OLE_CAT_ACTION_S INCREMENT BY 1 START WITH 21 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_CAT_CMPLT_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_CAT_CMPLT_S'; END IF;
END;
/
CREATE SEQUENCE OLE_CAT_CMPLT_S INCREMENT BY 1 START WITH 21 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_CAT_ELA_RLSHP_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_CAT_ELA_RLSHP_S'; END IF;
END;
/
CREATE SEQUENCE OLE_CAT_ELA_RLSHP_S INCREMENT BY 1 START WITH 21 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_CAT_ENCD_LVL_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_CAT_ENCD_LVL_S'; END IF;
END;
/
CREATE SEQUENCE OLE_CAT_ENCD_LVL_S INCREMENT BY 1 START WITH 21 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_CAT_FLD_ENCD_LVL_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_CAT_FLD_ENCD_LVL_S'; END IF;
END;
/
CREATE SEQUENCE OLE_CAT_FLD_ENCD_LVL_S INCREMENT BY 1 START WITH 21 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_CAT_GEN_RTN_POL_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_CAT_GEN_RTN_POL_S'; END IF;
END;
/
CREATE SEQUENCE OLE_CAT_GEN_RTN_POL_S INCREMENT BY 1 START WITH 21 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_CAT_ITM_TYP_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_CAT_ITM_TYP_S'; END IF;
END;
/
CREATE SEQUENCE OLE_CAT_ITM_TYP_S INCREMENT BY 1 START WITH 61 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_CAT_LND_POL_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_CAT_LND_POL_S'; END IF;
END;
/
CREATE SEQUENCE OLE_CAT_LND_POL_S INCREMENT BY 1 START WITH 21 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_CAT_LOC_COUNTRY_CD_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_CAT_LOC_COUNTRY_CD_S'; END IF;
END;
/
CREATE SEQUENCE OLE_CAT_LOC_COUNTRY_CD_S INCREMENT BY 1 START WITH 21 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_CAT_LOC_STATUS_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_CAT_LOC_STATUS_S'; END IF;
END;
/
CREATE SEQUENCE OLE_CAT_LOC_STATUS_S INCREMENT BY 1 START WITH 21 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_CAT_NTN_TYP_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_CAT_NTN_TYP_S'; END IF;
END;
/
CREATE SEQUENCE OLE_CAT_NTN_TYP_S INCREMENT BY 1 START WITH 21 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_CAT_PRVCY_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_CAT_PRVCY_S'; END IF;
END;
/
CREATE SEQUENCE OLE_CAT_PRVCY_S INCREMENT BY 1 START WITH 21 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_CAT_RCPT_STAT_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_CAT_RCPT_STAT_S'; END IF;
END;
/
CREATE SEQUENCE OLE_CAT_RCPT_STAT_S INCREMENT BY 1 START WITH 21 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_CAT_REC_TYP_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_CAT_REC_TYP_S'; END IF;
END;
/
CREATE SEQUENCE OLE_CAT_REC_TYP_S INCREMENT BY 1 START WITH 21 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_CAT_REPRO_POL_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_CAT_REPRO_POL_S'; END IF;
END;
/
CREATE SEQUENCE OLE_CAT_REPRO_POL_S INCREMENT BY 1 START WITH 21 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_CAT_SHVLG_ORD_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_CAT_SHVLG_ORD_S'; END IF;
END;
/
CREATE SEQUENCE OLE_CAT_SHVLG_ORD_S INCREMENT BY 1 START WITH 21 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_CAT_SHVLG_SCHM_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_CAT_SHVLG_SCHM_S'; END IF;
END;
/
CREATE SEQUENCE OLE_CAT_SHVLG_SCHM_S INCREMENT BY 1 START WITH 21 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_CAT_SPCP_RPT_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_CAT_SPCP_RPT_S'; END IF;
END;
/
CREATE SEQUENCE OLE_CAT_SPCP_RPT_S INCREMENT BY 1 START WITH 21 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_CAT_SPFC_RTN_POL_TYP_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_CAT_SPFC_RTN_POL_TYP_S'; END IF;
END;
/
CREATE SEQUENCE OLE_CAT_SPFC_RTN_POL_TYP_S INCREMENT BY 1 START WITH 21 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_CAT_SPFC_RTN_POL_UNT_TYP_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_CAT_SPFC_RTN_POL_UNT_TYP_S'; END IF;
END;
/
CREATE SEQUENCE OLE_CAT_SPFC_RTN_POL_UNT_TYP_S INCREMENT BY 1 START WITH 21 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_CAT_SRC_TRM_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_CAT_SRC_TRM_S'; END IF;
END;
/
CREATE SEQUENCE OLE_CAT_SRC_TRM_S INCREMENT BY 1 START WITH 21 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_CAT_TYPE_OWNERSHIP_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_CAT_TYPE_OWNERSHIP_S'; END IF;
END;
/
CREATE SEQUENCE OLE_CAT_TYPE_OWNERSHIP_S INCREMENT BY 1 START WITH 21 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_CA_ACCT_ENCUM_CNSTRT_T_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_CA_ACCT_ENCUM_CNSTRT_T_SEQ'; END IF;
END;
/
CREATE SEQUENCE OLE_CA_ACCT_ENCUM_CNSTRT_T_SEQ INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_CA_ACCT_EXP_CNSTRT_T_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_CA_ACCT_EXP_CNSTRT_T_SEQ'; END IF;
END;
/
CREATE SEQUENCE OLE_CA_ACCT_EXP_CNSTRT_T_SEQ INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_CA_ACCT_LGCY_LMS_FND_T_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_CA_ACCT_LGCY_LMS_FND_T_SEQ'; END IF;
END;
/
CREATE SEQUENCE OLE_CA_ACCT_LGCY_LMS_FND_T_SEQ INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_CA_ACCT_SFC_TYPE_T_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_CA_ACCT_SFC_TYPE_T_SEQ'; END IF;
END;
/
CREATE SEQUENCE OLE_CA_ACCT_SFC_TYPE_T_SEQ INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_CA_ACCT_STWD_TYP_T_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_CA_ACCT_STWD_TYP_T_SEQ'; END IF;
END;
/
CREATE SEQUENCE OLE_CA_ACCT_STWD_TYP_T_SEQ INCREMENT BY 1 START WITH 1010 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_CA_ACCT_STWD_T_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_CA_ACCT_STWD_T_SEQ'; END IF;
END;
/
CREATE SEQUENCE OLE_CA_ACCT_STWD_T_SEQ INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_CNSTRT_TYP_T_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_CNSTRT_TYP_T_SEQ'; END IF;
END;
/
CREATE SEQUENCE OLE_CNSTRT_TYP_T_SEQ INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_CURR_TYP_ID_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_CURR_TYP_ID_S'; END IF;
END;
/
CREATE SEQUENCE OLE_CURR_TYP_ID_S INCREMENT BY 1 START WITH 1 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_DEFAULTABLE_COLUMN_ID_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_DEFAULTABLE_COLUMN_ID_S'; END IF;
END;
/
CREATE SEQUENCE OLE_DEFAULTABLE_COLUMN_ID_S INCREMENT BY 1 START WITH 1 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_DEFAULT_VALUE_ID_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_DEFAULT_VALUE_ID_S'; END IF;
END;
/
CREATE SEQUENCE OLE_DEFAULT_VALUE_ID_S INCREMENT BY 1 START WITH 1 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_EDI_TYP_CON_ID_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_EDI_TYP_CON_ID_S'; END IF;
END;
/
CREATE SEQUENCE OLE_EDI_TYP_CON_ID_S INCREMENT BY 1 START WITH 1 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_FRMT_ID_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_FRMT_ID_S'; END IF;
END;
/
CREATE SEQUENCE OLE_FRMT_ID_S INCREMENT BY 1 START WITH 8 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_INV_SUB_TYP_T_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_INV_SUB_TYP_T_SEQ'; END IF;
END;
/
CREATE SEQUENCE OLE_INV_SUB_TYP_T_SEQ INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_INV_TYP_T_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_INV_TYP_T_SEQ'; END IF;
END;
/
CREATE SEQUENCE OLE_INV_TYP_T_SEQ INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_ITM_PRC_SRC_ID_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_ITM_PRC_SRC_ID_S'; END IF;
END;
/
CREATE SEQUENCE OLE_ITM_PRC_SRC_ID_S INCREMENT BY 1 START WITH 1 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_NTE_TYP_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_NTE_TYP_SEQ'; END IF;
END;
/
CREATE SEQUENCE OLE_NTE_TYP_SEQ INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_PMT_MTHD_T_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_PMT_MTHD_T_SEQ'; END IF;
END;
/
CREATE SEQUENCE OLE_PMT_MTHD_T_SEQ INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_PMT_RQST_ITM_NTE_T_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_PMT_RQST_ITM_NTE_T_SEQ'; END IF;
END;
/
CREATE SEQUENCE OLE_PMT_RQST_ITM_NTE_T_SEQ INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_PUR_CAT_ID_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_PUR_CAT_ID_S'; END IF;
END;
/
CREATE SEQUENCE OLE_PUR_CAT_ID_S INCREMENT BY 1 START WITH 16 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_PUR_PO_ERR_CDS_T_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_PUR_PO_ERR_CDS_T_SEQ'; END IF;
END;
/
CREATE SEQUENCE OLE_PUR_PO_ERR_CDS_T_SEQ INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_PUR_PO_FAIL_DOC_T_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_PUR_PO_FAIL_DOC_T_SEQ'; END IF;
END;
/
CREATE SEQUENCE OLE_PUR_PO_FAIL_DOC_T_SEQ INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_PUR_PO_ITM_NTE_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_PUR_PO_ITM_NTE_SEQ'; END IF;
END;
/
CREATE SEQUENCE OLE_PUR_PO_ITM_NTE_SEQ INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_PUR_PO_LOAD_SUM_T_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_PUR_PO_LOAD_SUM_T_SEQ'; END IF;
END;
/
CREATE SEQUENCE OLE_PUR_PO_LOAD_SUM_T_SEQ INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_PUR_PO_PRFL_T_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_PUR_PO_PRFL_T_SEQ'; END IF;
END;
/
CREATE SEQUENCE OLE_PUR_PO_PRFL_T_SEQ INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_PUR_RCVCOR_LN_ITM_DOC_ID_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_PUR_RCVCOR_LN_ITM_DOC_ID_S'; END IF;
END;
/
CREATE SEQUENCE OLE_PUR_RCVCOR_LN_ITM_DOC_ID_S INCREMENT BY 1 START WITH 1 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_PUR_RCVNG_LN_ITM_EXC_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_PUR_RCVNG_LN_ITM_EXC_SEQ'; END IF;
END;
/
CREATE SEQUENCE OLE_PUR_RCVNG_LN_ITM_EXC_SEQ INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_PUR_RCVNG_LN_ITM_NTE_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_PUR_RCVNG_LN_ITM_NTE_SEQ'; END IF;
END;
/
CREATE SEQUENCE OLE_PUR_RCVNG_LN_ITM_NTE_SEQ INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_PUR_RCV_LN_ITM_DOC_ID_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_PUR_RCV_LN_ITM_DOC_ID_S'; END IF;
END;
/
CREATE SEQUENCE OLE_PUR_RCV_LN_ITM_DOC_ID_S INCREMENT BY 1 START WITH 1 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_PUR_RCV_LN_ITM_EXC_MDC_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_PUR_RCV_LN_ITM_EXC_MDC_SEQ'; END IF;
END;
/
CREATE SEQUENCE OLE_PUR_RCV_LN_ITM_EXC_MDC_SEQ INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_PUR_REQS_ITM_T_NTE_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_PUR_REQS_ITM_T_NTE_SEQ'; END IF;
END;
/
CREATE SEQUENCE OLE_PUR_REQS_ITM_T_NTE_SEQ INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_PUR_REQ_RCPT_STATUS_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_PUR_REQ_RCPT_STATUS_SEQ'; END IF;
END;
/
CREATE SEQUENCE OLE_PUR_REQ_RCPT_STATUS_SEQ INCREMENT BY 1 START WITH 1 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_PUR_VNDR_ALIAS_ID_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_PUR_VNDR_ALIAS_ID_SEQ'; END IF;
END;
/
CREATE SEQUENCE OLE_PUR_VNDR_ALIAS_ID_SEQ INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_RCVNG_COR_LN_ITM_EXC_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_RCVNG_COR_LN_ITM_EXC_SEQ'; END IF;
END;
/
CREATE SEQUENCE OLE_RCVNG_COR_LN_ITM_EXC_SEQ INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_RCVNG_COR_LN_ITM_NTE_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_RCVNG_COR_LN_ITM_NTE_SEQ'; END IF;
END;
/
CREATE SEQUENCE OLE_RCVNG_COR_LN_ITM_NTE_SEQ INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_REQSTR_TYP_ID_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_REQSTR_TYP_ID_S'; END IF;
END;
/
CREATE SEQUENCE OLE_REQSTR_TYP_ID_S INCREMENT BY 1 START WITH 1 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_REQ_SRC_TYP_ID_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_REQ_SRC_TYP_ID_S'; END IF;
END;
/
CREATE SEQUENCE OLE_REQ_SRC_TYP_ID_S INCREMENT BY 1 START WITH 7 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_RQSTR_ID_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_RQSTR_ID_S'; END IF;
END;
/
CREATE SEQUENCE OLE_RQSTR_ID_S INCREMENT BY 1 START WITH 1 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_VNDR_TRANS_FRMT_ID_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_VNDR_TRANS_FRMT_ID_S'; END IF;
END;
/
CREATE SEQUENCE OLE_VNDR_TRANS_FRMT_ID_S INCREMENT BY 1 START WITH 1 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_LIC_REQ_DET_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_LIC_REQ_DET_S'; END IF;
END;
/
CREATE SEQUENCE OLE_LIC_REQ_DET_S INCREMENT BY 1 START WITH 1 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'ORIGIN_ENTRY_ID_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE ORIGIN_ENTRY_ID_SEQ'; END IF;
END;
/
CREATE SEQUENCE ORIGIN_ENTRY_ID_SEQ INCREMENT BY 1 START WITH 2060 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PDP_ACH_ACCT_GNRTD_ID_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PDP_ACH_ACCT_GNRTD_ID_SEQ'; END IF;
END;
/
CREATE SEQUENCE PDP_ACH_ACCT_GNRTD_ID_SEQ INCREMENT BY 1 START WITH 10000000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PDP_BNK_ID_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PDP_BNK_ID_SEQ'; END IF;
END;
/
CREATE SEQUENCE PDP_BNK_ID_SEQ INCREMENT BY 1 START WITH 11000001 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PDP_CUST_BNK_ID_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PDP_CUST_BNK_ID_SEQ'; END IF;
END;
/
CREATE SEQUENCE PDP_CUST_BNK_ID_SEQ INCREMENT BY 1 START WITH 10000034 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PDP_CUST_ID_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PDP_CUST_ID_SEQ'; END IF;
END;
/
CREATE SEQUENCE PDP_CUST_ID_SEQ INCREMENT BY 1 START WITH 10000200 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PDP_DOC_TYP_ID_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PDP_DOC_TYP_ID_SEQ'; END IF;
END;
/
CREATE SEQUENCE PDP_DOC_TYP_ID_SEQ INCREMENT BY 1 START WITH 10000002 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PDP_GL_PENDING_ENTRY_ID_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PDP_GL_PENDING_ENTRY_ID_SEQ'; END IF;
END;
/
CREATE SEQUENCE PDP_GL_PENDING_ENTRY_ID_SEQ INCREMENT BY 1 START WITH 10011479 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PDP_PMT_ACCT_DTL_ID_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PDP_PMT_ACCT_DTL_ID_SEQ'; END IF;
END;
/
CREATE SEQUENCE PDP_PMT_ACCT_DTL_ID_SEQ INCREMENT BY 1 START WITH 10005615 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PDP_PMT_ACCT_HIST_ID_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PDP_PMT_ACCT_HIST_ID_SEQ'; END IF;
END;
/
CREATE SEQUENCE PDP_PMT_ACCT_HIST_ID_SEQ INCREMENT BY 1 START WITH 10020334 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PDP_PMT_DTL_ID_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PDP_PMT_DTL_ID_SEQ'; END IF;
END;
/
CREATE SEQUENCE PDP_PMT_DTL_ID_SEQ INCREMENT BY 1 START WITH 10001767 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PDP_PMT_FIL_ID_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PDP_PMT_FIL_ID_SEQ'; END IF;
END;
/
CREATE SEQUENCE PDP_PMT_FIL_ID_SEQ INCREMENT BY 1 START WITH 10000108 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PDP_PMT_GRP_HIST_ID_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PDP_PMT_GRP_HIST_ID_SEQ'; END IF;
END;
/
CREATE SEQUENCE PDP_PMT_GRP_HIST_ID_SEQ INCREMENT BY 1 START WITH 10000103 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PDP_PMT_GRP_ID_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PDP_PMT_GRP_ID_SEQ'; END IF;
END;
/
CREATE SEQUENCE PDP_PMT_GRP_ID_SEQ INCREMENT BY 1 START WITH 10001070 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PDP_PMT_NTE_ID_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PDP_PMT_NTE_ID_SEQ'; END IF;
END;
/
CREATE SEQUENCE PDP_PMT_NTE_ID_SEQ INCREMENT BY 1 START WITH 10012647 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PDP_PROC_ID_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PDP_PROC_ID_SEQ'; END IF;
END;
/
CREATE SEQUENCE PDP_PROC_ID_SEQ INCREMENT BY 1 START WITH 10000098 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PDP_PROC_SUM_ID_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PDP_PROC_SUM_ID_SEQ'; END IF;
END;
/
CREATE SEQUENCE PDP_PROC_SUM_ID_SEQ INCREMENT BY 1 START WITH 10000099 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PMT_CHG_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PMT_CHG_ID'; END IF;
END;
/
CREATE SEQUENCE PMT_CHG_ID INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PMT_RQST_ACCT_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PMT_RQST_ACCT_ID'; END IF;
END;
/
CREATE SEQUENCE PMT_RQST_ACCT_ID INCREMENT BY 1 START WITH 1006 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PMT_RQST_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PMT_RQST_ID'; END IF;
END;
/
CREATE SEQUENCE PMT_RQST_ID INCREMENT BY 1 START WITH 1060 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PMT_RQST_ITM_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PMT_RQST_ITM_ID'; END IF;
END;
/
CREATE SEQUENCE PMT_RQST_ITM_ID INCREMENT BY 1 START WITH 1020 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PMT_RQST_STAT_HIST_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PMT_RQST_STAT_HIST_ID'; END IF;
END;
/
CREATE SEQUENCE PMT_RQST_STAT_HIST_ID INCREMENT BY 1 START WITH 1002 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PO_ACCT_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PO_ACCT_ID'; END IF;
END;
/
CREATE SEQUENCE PO_ACCT_ID INCREMENT BY 1 START WITH 1007 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PO_CONTR_LANG_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PO_CONTR_LANG_ID'; END IF;
END;
/
CREATE SEQUENCE PO_CONTR_LANG_ID INCREMENT BY 1 START WITH 1002 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PO_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PO_ID'; END IF;
END;
/
CREATE SEQUENCE PO_ID INCREMENT BY 1 START WITH 1007 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PO_ITM_CPTL_AST_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PO_ITM_CPTL_AST_ID'; END IF;
END;
/
CREATE SEQUENCE PO_ITM_CPTL_AST_ID INCREMENT BY 1 START WITH 1002 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PO_ITM_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PO_ITM_ID'; END IF;
END;
/
CREATE SEQUENCE PO_ITM_ID INCREMENT BY 1 START WITH 1009 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PO_QT_LANG_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PO_QT_LANG_ID'; END IF;
END;
/
CREATE SEQUENCE PO_QT_LANG_ID INCREMENT BY 1 START WITH 1002 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PO_QT_LST_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PO_QT_LST_ID'; END IF;
END;
/
CREATE SEQUENCE PO_QT_LST_ID INCREMENT BY 1 START WITH 1004 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PO_RSTRC_MTRL_STATHST_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PO_RSTRC_MTRL_STATHST_ID'; END IF;
END;
/
CREATE SEQUENCE PO_RSTRC_MTRL_STATHST_ID INCREMENT BY 1 START WITH 1002 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PO_STAT_HIST_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PO_STAT_HIST_ID'; END IF;
END;
/
CREATE SEQUENCE PO_STAT_HIST_ID INCREMENT BY 1 START WITH 1002 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PO_VNDR_QT_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PO_VNDR_QT_ID'; END IF;
END;
/
CREATE SEQUENCE PO_VNDR_QT_ID INCREMENT BY 1 START WITH 1002 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PO_VNDR_STPLTN_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PO_VNDR_STPLTN_ID'; END IF;
END;
/
CREATE SEQUENCE PO_VNDR_STPLTN_ID INCREMENT BY 1 START WITH 1002 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PUR_PO_CPTL_AST_ITM_ID_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PUR_PO_CPTL_AST_ITM_ID_SEQ'; END IF;
END;
/
CREATE SEQUENCE PUR_PO_CPTL_AST_ITM_ID_SEQ INCREMENT BY 1 START WITH 1 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PUR_PO_CPTL_AST_LOC_ID_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PUR_PO_CPTL_AST_LOC_ID_SEQ'; END IF;
END;
/
CREATE SEQUENCE PUR_PO_CPTL_AST_LOC_ID_SEQ INCREMENT BY 1 START WITH 1 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PUR_PO_CPTL_AST_SYS_ID_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PUR_PO_CPTL_AST_SYS_ID_SEQ'; END IF;
END;
/
CREATE SEQUENCE PUR_PO_CPTL_AST_SYS_ID_SEQ INCREMENT BY 1 START WITH 1 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PUR_PO_ITM_USE_TAX_ID_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PUR_PO_ITM_USE_TAX_ID_SEQ'; END IF;
END;
/
CREATE SEQUENCE PUR_PO_ITM_USE_TAX_ID_SEQ INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PUR_RCVNG_ADDR_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PUR_RCVNG_ADDR_ID'; END IF;
END;
/
CREATE SEQUENCE PUR_RCVNG_ADDR_ID INCREMENT BY 1 START WITH 1002 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PUR_REQS_CPTL_AST_ITM_ID_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PUR_REQS_CPTL_AST_ITM_ID_SEQ'; END IF;
END;
/
CREATE SEQUENCE PUR_REQS_CPTL_AST_ITM_ID_SEQ INCREMENT BY 1 START WITH 1 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PUR_REQS_CPTL_AST_LOC_ID_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PUR_REQS_CPTL_AST_LOC_ID_SEQ'; END IF;
END;
/
CREATE SEQUENCE PUR_REQS_CPTL_AST_LOC_ID_SEQ INCREMENT BY 1 START WITH 1 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PUR_REQS_CPTL_AST_SYS_ID_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PUR_REQS_CPTL_AST_SYS_ID_SEQ'; END IF;
END;
/
CREATE SEQUENCE PUR_REQS_CPTL_AST_SYS_ID_SEQ INCREMENT BY 1 START WITH 1 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PUR_REQS_ITM_USE_TAX_ID_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PUR_REQS_ITM_USE_TAX_ID_SEQ'; END IF;
END;
/
CREATE SEQUENCE PUR_REQS_ITM_USE_TAX_ID_SEQ INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PUR_SNSTV_DTA_ASGN_ID_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PUR_SNSTV_DTA_ASGN_ID_SEQ'; END IF;
END;
/
CREATE SEQUENCE PUR_SNSTV_DTA_ASGN_ID_SEQ INCREMENT BY 1 START WITH 2000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PUR_THRSHLD_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PUR_THRSHLD_ID'; END IF;
END;
/
CREATE SEQUENCE PUR_THRSHLD_ID INCREMENT BY 1 START WITH 1007 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'PUR_VNDR_EXCL_MTCH_T_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE PUR_VNDR_EXCL_MTCH_T_SEQ'; END IF;
END;
/
CREATE SEQUENCE PUR_VNDR_EXCL_MTCH_T_SEQ INCREMENT BY 1 START WITH 1 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'RCVNG_COR_ITM_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE RCVNG_COR_ITM_ID'; END IF;
END;
/
CREATE SEQUENCE RCVNG_COR_ITM_ID INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'RCVNG_LN_ITM_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE RCVNG_LN_ITM_ID'; END IF;
END;
/
CREATE SEQUENCE RCVNG_LN_ITM_ID INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'REQS_ACCT_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE REQS_ACCT_ID'; END IF;
END;
/
CREATE SEQUENCE REQS_ACCT_ID INCREMENT BY 1 START WITH 1003 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'REQS_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE REQS_ID'; END IF;
END;
/
CREATE SEQUENCE REQS_ID INCREMENT BY 1 START WITH 1003 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'REQS_ITM_CPTL_AST_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE REQS_ITM_CPTL_AST_ID'; END IF;
END;
/
CREATE SEQUENCE REQS_ITM_CPTL_AST_ID INCREMENT BY 1 START WITH 1002 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'REQS_ITM_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE REQS_ITM_ID'; END IF;
END;
/
CREATE SEQUENCE REQS_ITM_ID INCREMENT BY 1 START WITH 1005 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'REQS_STAT_HIST_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE REQS_STAT_HIST_ID'; END IF;
END;
/
CREATE SEQUENCE REQS_STAT_HIST_ID INCREMENT BY 1 START WITH 1006 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'SHPMNT_RCVNG_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE SHPMNT_RCVNG_ID'; END IF;
END;
/
CREATE SEQUENCE SHPMNT_RCVNG_ID INCREMENT BY 1 START WITH 1002 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'VNDR_ADDR_GNRTD_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE VNDR_ADDR_GNRTD_ID'; END IF;
END;
/
CREATE SEQUENCE VNDR_ADDR_GNRTD_ID INCREMENT BY 1 START WITH 12105 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'VNDR_CNTCT_GNRTD_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE VNDR_CNTCT_GNRTD_ID'; END IF;
END;
/
CREATE SEQUENCE VNDR_CNTCT_GNRTD_ID INCREMENT BY 1 START WITH 12005 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'VNDR_CNTCT_PHN_GNRTD_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE VNDR_CNTCT_PHN_GNRTD_ID'; END IF;
END;
/
CREATE SEQUENCE VNDR_CNTCT_PHN_GNRTD_ID INCREMENT BY 1 START WITH 12005 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'VNDR_CONTR_GNRTD_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE VNDR_CONTR_GNRTD_ID'; END IF;
END;
/
CREATE SEQUENCE VNDR_CONTR_GNRTD_ID INCREMENT BY 1 START WITH 12105 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'VNDR_CUST_NBR_GNRTD_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE VNDR_CUST_NBR_GNRTD_ID'; END IF;
END;
/
CREATE SEQUENCE VNDR_CUST_NBR_GNRTD_ID INCREMENT BY 1 START WITH 12005 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'VNDR_DFLT_ADDR_GNRTD_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE VNDR_DFLT_ADDR_GNRTD_ID'; END IF;
END;
/
CREATE SEQUENCE VNDR_DFLT_ADDR_GNRTD_ID INCREMENT BY 1 START WITH 12005 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'VNDR_HDR_GNRTD_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE VNDR_HDR_GNRTD_ID'; END IF;
END;
/
CREATE SEQUENCE VNDR_HDR_GNRTD_ID INCREMENT BY 1 START WITH 12105 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'VNDR_PHN_GNRTD_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE VNDR_PHN_GNRTD_ID'; END IF;
END;
/
CREATE SEQUENCE VNDR_PHN_GNRTD_ID INCREMENT BY 1 START WITH 12005 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'VNDR_STPLTN_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE VNDR_STPLTN_ID'; END IF;
END;
/
CREATE SEQUENCE VNDR_STPLTN_ID INCREMENT BY 1 START WITH 10003 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'VNDR_TAX_CHG_GNRTD_ID';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE VNDR_TAX_CHG_GNRTD_ID'; END IF;
END;
/
CREATE SEQUENCE VNDR_TAX_CHG_GNRTD_ID INCREMENT BY 1 START WITH 12032 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_AP_INV_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_AP_INV_SEQ'; END IF;
END;
/
CREATE SEQUENCE OLE_AP_INV_SEQ INCREMENT BY 1 START WITH 1 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_AP_INV_PO_ITM_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_AP_INV_PO_ITM_SEQ'; END IF;
END;
/
CREATE SEQUENCE OLE_AP_INV_PO_ITM_SEQ INCREMENT BY 1 START WITH 1 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_AP_INV_ACCT_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_AP_INV_ACCT_SEQ'; END IF;
END;
/
CREATE SEQUENCE OLE_AP_INV_ACCT_SEQ INCREMENT BY 1 START WITH 1 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_AP_INV_SUM_ACCT_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_AP_INV_SUM_ACCT_SEQ'; END IF;
END;
/
CREATE SEQUENCE OLE_AP_INV_SUM_ACCT_SEQ INCREMENT BY 1 START WITH 1 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_AP_INV_PO_ITM_USE_TAX_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_AP_INV_PO_ITM_USE_TAX_SEQ'; END IF;
END;
/
CREATE SEQUENCE OLE_AP_INV_PO_ITM_USE_TAX_SEQ INCREMENT BY 1 START WITH 1 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_AP_INV_ACCT_CHG_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_AP_INV_ACCT_CHG_SEQ'; END IF;
END;
/
CREATE SEQUENCE OLE_AP_INV_ACCT_CHG_SEQ INCREMENT BY 1 START WITH 1 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_AP_INV_ITM_NTE_T_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_AP_INV_ITM_NTE_T_SEQ'; END IF;
END;
/
CREATE SEQUENCE OLE_AP_INV_ITM_NTE_T_SEQ INCREMENT BY 1 START WITH 1 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_COPY_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_COPY_S'; END IF;
END;
/
CREATE SEQUENCE OLE_COPY_S INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_PAID_COPY_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_PAID_COPY_S'; END IF;
END;
/
CREATE SEQUENCE OLE_PAID_COPY_S INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_AP_INV_OFFSET_ACCT_SEQ';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_AP_INV_OFFSET_ACCT_SEQ'; END IF;
END;
/
CREATE SEQUENCE OLE_AP_INV_OFFSET_ACCT_SEQ INCREMENT BY 1 START WITH 1 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_LINK_PURAP_DONOR_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_LINK_PURAP_DONOR_S'; END IF;
END;
/
CREATE SEQUENCE OLE_LINK_PURAP_DONOR_S INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_PO_CLM_HIS_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_PO_CLM_HIS_S'; END IF;
END;
/
CREATE SEQUENCE OLE_PO_CLM_HIS_S INCREMENT BY 1 START WITH 1 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_INV_ING_DET_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_INV_ING_DET_S'; END IF;
END;
/
CREATE SEQUENCE OLE_INV_ING_DET_S INCREMENT BY 1 START WITH 1 NOMAXVALUE NOCYCLE NOCACHE ORDER
/
DECLARE temp NUMBER;
BEGIN
SELECT COUNT(*) INTO temp FROM user_sequences WHERE sequence_name = 'OLE_EXCHANGE_RT_ID_S';
IF temp > 0 THEN EXECUTE IMMEDIATE 'DROP SEQUENCE OLE_EXCHANGE_RT_ID_S'; END IF;
END;
/
CREATE SEQUENCE OLE_EXCHANGE_RT_ID_S INCREMENT BY 1 START WITH 20 NOMAXVALUE NOCYCLE NOCACHE ORDER
/