/**Begin E:\NextERP_PDM\PDM_UPGRADE\PDMS\branch_lastest\pdm\SRC_table.sql **/
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_SRC_TIMECHG' AND KSQL_COL_NAME ='FREPLYDATE') 
 ALTER TABLE T_SRC_TIMECHG ADD (FREPLYDATE DATETIME );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_SRC_TIMECHG' AND KSQL_COL_NAME ='FNEWREPLYDATE') 
 ALTER TABLE T_SRC_TIMECHG ADD (FNEWREPLYDATE DATETIME );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_SRC_SCOREDETAIL' AND KSQL_COL_NAME ='FSRCENTRYID') 
 ALTER TABLE T_SRC_SCOREDETAIL ADD (FSRCENTRYID BIGINT DEFAULT 0 NOT NULL );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_SRC_MEMBERENTRY' AND KSQL_COL_NAME ='FREMARK') 
 ALTER TABLE T_SRC_MEMBERENTRY ADD (FREMARK NVARCHAR(255) DEFAULT ' ' NOT NULL );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_SRC_MEMBERENTRY' AND KSQL_COL_NAME ='FCLARIFYTIME') 
 ALTER TABLE T_SRC_MEMBERENTRY ADD (FCLARIFYTIME DATETIME );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_SRC_CONTRACTENTRY_L' AND KSQL_COL_NAME ='FENTRYID') 
 ALTER TABLE T_SRC_CONTRACTENTRY_L ADD (FENTRYID BIGINT DEFAULT 0 NOT NULL );

/**End E:\NextERP_PDM\PDM_UPGRADE\PDMS\branch_lastest\pdm\SRC_table.sql **/
