/**Begin E:\NextERP_PDM\PDM_UPGRADE\PDMS\branch_lastest\pdm\BCM_table.sql **/

IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_BCM_DATETYPEEDITCYCLE' AND KSQL_COL_NAME IN ('FVERSIONNAME')) 
ALTER TABLE T_BCM_DATETYPEEDITCYCLE ADD (FVERSIONNAME NVARCHAR(50) DEFAULT ' ');
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_BCM_DATETYPEEDITCYCLE' AND KSQL_COL_NAME IN ('FVERSION')) 
ALTER TABLE T_BCM_DATETYPEEDITCYCLE ADD (FVERSION BIGINT DEFAULT 0);
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_BCM_DATETYPEEDITCYCLE' AND KSQL_COL_NAME IN ('FDESCRIBE')) 
ALTER TABLE T_BCM_DATETYPEEDITCYCLE ADD (FDESCRIBE NVARCHAR(255) DEFAULT ' ');
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_BCM_DATETYPEEDITCYCLE' AND KSQL_COL_NAME IN ('FLATESTMODIFIERID')) 
ALTER TABLE T_BCM_DATETYPEEDITCYCLE ADD (FLATESTMODIFIERID BIGINT DEFAULT 0);
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_BCM_DATETYPEEDITCYCLE' AND KSQL_COL_NAME IN ('FLATESTMODIFYDATE')) 
ALTER TABLE T_BCM_DATETYPEEDITCYCLE ADD (FLATESTMODIFYDATE DATETIME);

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