/**Begin E:\NextERP_PDM\PDM_UPGRADE\PDMS\branch_lastest(平台_业务)\pdm\BCM_constraint.sql **/
 EXEC P_ALTERPK 'PK_T_BCM_CHKATTACHMENT', 'T_BCM_CHKATTACHMENT', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'T_BCM_CHKATTACHMENT_RPT') CREATE INDEX T_BCM_CHKATTACHMENT_RPT ON T_BCM_CHKATTACHMENT ( FREPORTID );


 EXEC P_ALTERPK 'PK_T_BCM_CHKNOTE', 'T_BCM_CHKNOTE', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'T_BCM_CHKNOTE_NOTE') CREATE INDEX T_BCM_CHKNOTE_NOTE ON T_BCM_CHKNOTE ( FNODEINFOID );


 EXEC P_ALTERPK 'PK_T_BCM_CHKNOTEINFO', 'T_BCM_CHKNOTEINFO', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'T_BCM_CHKNOTEINFO_DIM') CREATE INDEX T_BCM_CHKNOTEINFO_DIM ON T_BCM_CHKNOTEINFO ( FMODEL ,FDIMSTR );



/**End E:\NextERP_PDM\PDM_UPGRADE\PDMS\branch_lastest(平台_业务)\pdm\BCM_constraint.sql **/
