/**Begin E:\NextERP_PDM\PDM_UPGRADE\PDMS\branch_lastest\pdm\BOS_constraint.sql **/
 EXEC P_ALTERPK 'PK_T_BD_ACCPURPOSEEXC', 'T_BD_ACCPURPOSEEXC', 'FDATAID,FUSEORGID', '0';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_T_BD_ACCPURPOSEEXC_ORG') CREATE  CLUSTERED INDEX IDX_T_BD_ACCPURPOSEEXC_ORG ON T_BD_ACCPURPOSEEXC ( FCREATEORGID );


 EXEC P_ALTERPK 'PK_T_BD_ACCPURPOSEUSEREG', 'T_BD_ACCPURPOSEUSEREG', 'FUSEORGID,FDATAID', '0';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_T_BD_ACCPURPOSEUREG_DATA') CREATE  CLUSTERED INDEX IDX_T_BD_ACCPURPOSEUREG_DATA ON T_BD_ACCPURPOSEUSEREG ( FDATAID );



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