/**Begin D:\PDM_UPGRADE\PDM1\MRP_table.sql **/
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_MRP_CALDETAILENTRY' AND KSQL_COL_NAME ='FDEMANDWAREHOUSE')
 ALTER TABLE T_MRP_CALDETAILENTRY ADD (FDEMANDWAREHOUSE BIGINT DEFAULT 0 NOT NULL );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_MRP_CALDETAILENTRY' AND KSQL_COL_NAME ='FSUPPLYPLANSCOPE')
 ALTER TABLE T_MRP_CALDETAILENTRY ADD (FSUPPLYPLANSCOPE BIGINT DEFAULT 0 NOT NULL );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_MRP_CALDETAILENTRY' AND KSQL_COL_NAME ='FDEMANDPLANSCOPE')
 ALTER TABLE T_MRP_CALDETAILENTRY ADD (FDEMANDPLANSCOPE BIGINT DEFAULT 0 NOT NULL );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_MRP_PEGINFODATAENTRY' AND KSQL_COL_NAME ='FDEMANDPLANSCOPE')
 ALTER TABLE T_MRP_PEGINFODATAENTRY ADD (FDEMANDPLANSCOPE BIGINT DEFAULT 0 NOT NULL );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_MRP_PEGINFODATAENTRY' AND KSQL_COL_NAME ='FSUPPLYPLANSCOPE')
 ALTER TABLE T_MRP_PEGINFODATAENTRY ADD (FSUPPLYPLANSCOPE BIGINT DEFAULT 0 NOT NULL );

/**End D:\PDM_UPGRADE\PDM1\MRP_table.sql **/
