
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_AR_BUSBILLENTRY' AND KSQL_COL_NAME ='FINVOICECUSTOMERID') 
 ALTER TABLE T_AR_BUSBILLENTRY ADD (FINVOICECUSTOMERID BIGINT DEFAULT 0 NOT NULL );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_AR_BUSBILLENTRY' AND KSQL_COL_NAME ='FDELIVERCUSTOMERID') 
 ALTER TABLE T_AR_BUSBILLENTRY ADD (FDELIVERCUSTOMERID BIGINT DEFAULT 0 NOT NULL );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_AR_FINARBILLENTRY' AND KSQL_COL_NAME ='FINVOICECUSTOMERID') 
 ALTER TABLE T_AR_FINARBILLENTRY ADD (FINVOICECUSTOMERID BIGINT DEFAULT 0 NOT NULL );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_AR_FINARBILLENTRY' AND KSQL_COL_NAME ='FDELIVERCUSTOMERID') 
 ALTER TABLE T_AR_FINARBILLENTRY ADD (FDELIVERCUSTOMERID BIGINT DEFAULT 0 NOT NULL );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_AR_FINARBILL' AND KSQL_COL_NAME ='FPAYMENTCUSTOMERID') 
 ALTER TABLE T_AR_FINARBILL ADD (FPAYMENTCUSTOMERID BIGINT DEFAULT 0 NOT NULL );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_AR_BUSBILL' AND KSQL_COL_NAME ='FPAYMENTCUSTOMERID') 
 ALTER TABLE T_AR_BUSBILL ADD (FPAYMENTCUSTOMERID BIGINT DEFAULT 0 NOT NULL );

 IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_AR_REVCFMBILLENTRY' AND KSQL_COL_NAME ='FINVOICECUSTOMERID')
 ALTER TABLE T_AR_REVCFMBILLENTRY ADD (FINVOICECUSTOMERID BIGINT DEFAULT 0 NOT NULL );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_AR_REVCFMBILLENTRY' AND KSQL_COL_NAME ='FDELIVERCUSTOMERID')
 ALTER TABLE T_AR_REVCFMBILLENTRY ADD (FDELIVERCUSTOMERID BIGINT DEFAULT 0 NOT NULL );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_AR_REVCFMBILL' AND KSQL_COL_NAME ='FPAYMENTCUSTOMERID')
 ALTER TABLE T_AR_REVCFMBILL ADD (FPAYMENTCUSTOMERID BIGINT DEFAULT 0 NOT NULL );