/*付款申请单新增 报销单号、报销金额、挂账金额、当前未付金额*/
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_ER_APPLYPAYBILL' AND KSQL_COL_NAME ='FPUBLICREIMBILLNO')
ALTER TABLE T_ER_APPLYPAYBILL ADD (FPUBLICREIMBILLNO VARCHAR(30) DEFAULT ' ' NOT NULL );

IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_ER_APPLYPAYBILL' AND KSQL_COL_NAME ='freimburseamount')
ALTER TABLE T_ER_APPLYPAYBILL ADD (freimburseamount DECIMAL(23,10) DEFAULT 0 NOT NULL );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_ER_APPLYPAYBILL' AND KSQL_COL_NAME ='fonaccountamount')
ALTER TABLE T_ER_APPLYPAYBILL ADD (fonaccountamount DECIMAL(23,10) DEFAULT 0 NOT NULL );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_ER_APPLYPAYBILL' AND KSQL_COL_NAME ='fpubnotpayamount')
ALTER TABLE T_ER_APPLYPAYBILL ADD (fpubnotpayamount DECIMAL(23,10) DEFAULT 0 NOT NULL );

/*对公报销单 新增 挂账金额*/
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_ER_PUBREIMBILL' AND KSQL_COL_NAME ='fonaccountamount')
ALTER TABLE T_ER_PUBREIMBILL ADD (fonaccountamount  DECIMAL(23,10) DEFAULT 0 NOT NULL);
