/**Begin E:\NextERP_PDM\PDM_UPGRADE\PDMS\branch_lastest\pdm\BASE_constraint.sql **/
 EXEC P_ALTERPK 'PK_T_BD_CUSTOMER_BITREL', 'T_BD_CUSTOMER_BITREL', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_TABNAME = 'T_BD_CUSTOMER_BITREL' AND KSQL_INDNAME = 'IDX_BD_CUSTOMER_BITREL_OB') CREATE INDEX IDX_BD_CUSTOMER_BITREL_OB ON T_BD_CUSTOMER_BITREL ( FUSEORGID ,FBITINDEX );


 EXEC P_ALTERPK 'PK_T_BD_MATERIAL_BITREL', 'T_BD_MATERIAL_BITREL', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_TABNAME = 'T_BD_MATERIAL_BITREL' AND KSQL_INDNAME = 'IDX_BD_MATERIAL_BITREL_OB') CREATE INDEX IDX_BD_MATERIAL_BITREL_OB ON T_BD_MATERIAL_BITREL ( FUSEORGID ,FBITINDEX );


 EXEC P_ALTERPK 'PK_T_BD_SUPPLIER_BITREL', 'T_BD_SUPPLIER_BITREL', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_TABNAME = 'T_BD_SUPPLIER_BITREL' AND KSQL_INDNAME = 'IDX_BD_SUPPLIER_BITREL_OB') CREATE INDEX IDX_BD_SUPPLIER_BITREL_OB ON T_BD_SUPPLIER_BITREL ( FUSEORGID ,FBITINDEX );



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