/**Begin E:\NextERP_PDM\PDM_UPGRADE\PDMS\branch_lastest\pdm\MRP_table.sql **/
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_MRP_CPS_PLANPRO' AND KSQL_COL_NAME ='FISLET') 
 ALTER TABLE T_MRP_CPS_PLANPRO ADD (FISLET CHAR(1) DEFAULT '0' NOT NULL );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_MRP_CPS_PLANPRO' AND KSQL_COL_NAME ='FISLOTNUM') 
 ALTER TABLE T_MRP_CPS_PLANPRO ADD (FISLOTNUM CHAR(1) DEFAULT '0' NOT NULL );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_MRP_CPS_PLANPRO' AND KSQL_COL_NAME ='FISBATCH') 
 ALTER TABLE T_MRP_CPS_PLANPRO ADD (FISBATCH CHAR(1) DEFAULT '0' NOT NULL );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_MRP_CPS_PLANPRO' AND KSQL_COL_NAME ='FISADVTIME') 
 ALTER TABLE T_MRP_CPS_PLANPRO ADD (FISADVTIME CHAR(1) DEFAULT '0' NOT NULL );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_MRP_CPS_PLANPRO' AND KSQL_COL_NAME ='FISAUTODROPPLANBILL') 
 ALTER TABLE T_MRP_CPS_PLANPRO ADD (FISAUTODROPPLANBILL CHAR(1) DEFAULT '0' NOT NULL );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_MRP_CPS_PLANPRO' AND KSQL_COL_NAME ='FISAUTOACOLLABORATIVEBILL') 
 ALTER TABLE T_MRP_CPS_PLANPRO ADD (FISAUTOACOLLABORATIVEBILL CHAR(1) DEFAULT '0' NOT NULL );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_MRP_CPS_PLANPRO' AND KSQL_COL_NAME ='FISAUTOAUDITPLANBILL') 
 ALTER TABLE T_MRP_CPS_PLANPRO ADD (FISAUTOAUDITPLANBILL CHAR(1) DEFAULT '0' NOT NULL );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_MRP_CPS_PLANPRO' AND KSQL_COL_NAME ='FDROPTIMERANGE') 
 ALTER TABLE T_MRP_CPS_PLANPRO ADD (FDROPTIMERANGE INT DEFAULT 0 NOT NULL );
/**End E:\NextERP_PDM\PDM_UPGRADE\PDMS\branch_lastest\pdm\MRP_table.sql **/
