/**Begin E:\NextERP_PDM\PDM_UPGRADE\PDMS\branch_lastest\pdm\POM_table.sql **/
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_IM_MDC_OMCMPLINBILL' AND KSQL_COL_NAME ='FMODELTYPE') 
 ALTER TABLE T_IM_MDC_OMCMPLINBILL ADD (FMODELTYPE NVARCHAR(50) DEFAULT ' ' NOT NULL );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_IM_MDC_OMCPBILLENTRY' AND KSQL_COL_NAME ='FTECHNO') 
 ALTER TABLE T_IM_MDC_OMCPBILLENTRY ADD (FTECHNO NVARCHAR(50) DEFAULT ' ' NOT NULL );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_IM_MDC_OMCPBILLENTRY' AND KSQL_COL_NAME ='FTECHID') 
 ALTER TABLE T_IM_MDC_OMCPBILLENTRY ADD (FTECHID BIGINT DEFAULT 0 NOT NULL );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_IM_MDC_OMCPBILLENTRY' AND KSQL_COL_NAME ='FOPRENTRYSEQ') 
 ALTER TABLE T_IM_MDC_OMCPBILLENTRY ADD (FOPRENTRYSEQ BIGINT DEFAULT 0 NOT NULL );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_IM_MDC_OMCPBILLENTRY' AND KSQL_COL_NAME ='FOPRENTRYID') 
 ALTER TABLE T_IM_MDC_OMCPBILLENTRY ADD (FOPRENTRYID BIGINT DEFAULT 0 NOT NULL );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_IM_MDC_OMCPBILLENTRY' AND KSQL_COL_NAME ='FOPROPERATION') 
 ALTER TABLE T_IM_MDC_OMCPBILLENTRY ADD (FOPROPERATION NVARCHAR(50) DEFAULT ' ' NOT NULL );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_IM_MDC_OMCPBILLENTRY' AND KSQL_COL_NAME ='FOPROPERATIONNAME') 
 ALTER TABLE T_IM_MDC_OMCPBILLENTRY ADD (FOPROPERATIONNAME NVARCHAR(50) DEFAULT ' ' NOT NULL );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_IM_MDC_OMCPBILLENTRY' AND KSQL_COL_NAME ='FOPROPERATIONID') 
 ALTER TABLE T_IM_MDC_OMCPBILLENTRY ADD (FOPROPERATIONID BIGINT DEFAULT 0 NOT NULL );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_IM_MDC_OMCPBILLENTRY' AND KSQL_COL_NAME ='FOPRDESCRIPTION') 
 ALTER TABLE T_IM_MDC_OMCPBILLENTRY ADD (FOPRDESCRIPTION NVARCHAR(50) DEFAULT ' ' NOT NULL );

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