/**Begin E:\NextERP_PDM\PDM_UPGRADE\PDMS\branch_lastest\pdm\BCM_constraint.sql **/
 EXEC P_ALTERPK 'PK_T_BCM_BIZRULESCOPE', 'T_BCM_BIZRULESCOPE', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_BCM_BIZRULESCOPE_RULE') CREATE INDEX IDX_BCM_BIZRULESCOPE_RULE ON T_BCM_BIZRULESCOPE ( FBIZRULEID );


 EXEC P_ALTERPK 'PK_T_BCM_MODELOLAP_RECORD', 'T_BCM_MODELOLAP_RECORD', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_BCM_OLAP_RECORD') CREATE INDEX IDX_BCM_OLAP_RECORD ON T_BCM_MODELOLAP_RECORD ( FMODEL );


 EXEC P_ALTERPK 'PK_T_BCM_ISEASMAP', 'T_BCM_ISEASMAP', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_T_BCM_ISEASMAP_DIM') CREATE INDEX IDX_T_BCM_ISEASMAP_DIM ON T_BCM_ISEASMAP ( FEASNAME ,FDIMENSIONNUMBER );



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