-- 检修组件清单增加字段
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 't_pom_mrostockentry' AND KSQL_COL_NAME ='fconsiderminbatch')
ALTER TABLE t_pom_mrostockentry ADD (fconsiderminbatch CHAR(1) DEFAULT '0' NOT NULL );

-- 生产组件清单
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 't_pom_manustockentry' AND KSQL_COL_NAME ='fconsiderminbatch')
ALTER TABLE t_pom_manustockentry ADD (fconsiderminbatch CHAR(1) DEFAULT '0' NOT NULL );
-- 生产组件清单变更单
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 't_pom_xmanustockentry' AND KSQL_COL_NAME ='fconsiderminbatch')
ALTER TABLE t_pom_xmanustockentry ADD (fconsiderminbatch CHAR(1) DEFAULT '0' NOT NULL );

-- 委外组件明细变更日志
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 't_pom_stockchglogdetail' AND KSQL_COL_NAME ='fconsiderminbatch')
ALTER TABLE t_pom_stockchglogdetail ADD (fconsiderminbatch NVARCHAR(200) DEFAULT ' ' NOT NULL );