/**Begin E:\NextERP_PDM\PDM_UPGRADE\PDMS\branch_lastest\pdm\PDM_table.sql **/
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_PDM_MANUVERSION' AND KSQL_COL_NAME ='FINWARORG') 
 ALTER TABLE T_PDM_MANUVERSION ADD (FINWARORG BIGINT DEFAULT 0 NOT NULL );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_PDM_MANUVERSION' AND KSQL_COL_NAME ='FINWAREHOUSE') 
 ALTER TABLE T_PDM_MANUVERSION ADD (FINWAREHOUSE BIGINT DEFAULT 0 NOT NULL );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_PDM_MANUVERSION' AND KSQL_COL_NAME ='FINWARELOCATION') 
 ALTER TABLE T_PDM_MANUVERSION ADD (FINWARELOCATION BIGINT DEFAULT 0 NOT NULL );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_PDM_MANUVERSION' AND KSQL_COL_NAME ='FPERSON') 
 ALTER TABLE T_PDM_MANUVERSION ADD (FPERSON BIGINT DEFAULT 0 NOT NULL );

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