IF NOT EXISTS (SELECT 1 FROM KSQL_USERTABLES WHERE KSQL_TABNAME = 'T_ER_REIMBURSEBILL_A')
CREATE TABLE T_ER_REIMBURSEBILL_A
(
    FID                BIGINT  DEFAULT 0   NOT NULL,
    FISINVOICEMODIFIED CHAR(1) DEFAULT '0' NOT NULL
);
EXEC P_ALTERPK 'PK_ER_REIMBURSEBILL_A', 'T_ER_REIMBURSEBILL_A', 'FID', '1';
IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_ER_REIMBILL_A') CREATE INDEX IDX_ER_REIMBILL_A ON T_ER_REIMBURSEBILL_A ( FISINVOICEMODIFIED );

IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_ER_DAILYREIMBURSEBILL' AND KSQL_COL_NAME ='FISINVOICEMODIFIED')
ALTER TABLE T_ER_DAILYREIMBURSEBILL ADD (FISINVOICEMODIFIED CHAR(1) DEFAULT '0' NOT NULL );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_ER_PUBREIMBILL' AND KSQL_COL_NAME ='FISINVOICEMODIFIED')
ALTER TABLE T_ER_PUBREIMBILL ADD (FISINVOICEMODIFIED CHAR(1) DEFAULT '0' NOT NULL );