/**Begin C:\Users\rd_jin_gu\Documents\work\PDM_UPGRADE\PDM1\HRCS_constraint.sql **/
 EXEC P_ALTERPK 'PK_HRCS_LABELOBJECT', 'T_HRCS_LABELOBJECT', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_HRCS_LABELOBJECT') CREATE INDEX IDX_HRCS_LABELOBJECT ON T_HRCS_LABELOBJECT ( FNUMBER );


 EXEC P_ALTERPK 'PK_HRCS_LBLJOINENTITY', 'T_HRCS_LBLJOINENTITY', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_HRCS_LBLJOINENTITY') CREATE INDEX IDX_HRCS_LBLJOINENTITY ON T_HRCS_LBLJOINENTITY ( FLABELOBJECTID );


 EXEC P_ALTERPK 'PK_HRCS_LBLENTITYRELATION', 'T_HRCS_LBLENTITYRELATION', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_HRCS_LBLENTITYRELATION') CREATE INDEX IDX_HRCS_LBLENTITYRELATION ON T_HRCS_LBLENTITYRELATION ( FLABELOBJECTID );


 EXEC P_ALTERPK 'PK_HRCS_LBLENTITYRELENTRY', 'T_HRCS_LBLENTITYRELENTRY', 'FENTRYID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_HRCS_LBLENTITYRELENTRY') CREATE INDEX IDX_HRCS_LBLENTITYRELENTRY ON T_HRCS_LBLENTITYRELENTRY ( FID );


 EXEC P_ALTERPK 'PK_HRCS_LABELOBJECT_L', 'T_HRCS_LABELOBJECT_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_HRCS_LABELOBJECT_L') CREATE INDEX IDX_HRCS_LABELOBJECT_L ON T_HRCS_LABELOBJECT_L ( FID ,FLOCALEID );



/**End C:\Users\rd_jin_gu\Documents\work\PDM_UPGRADE\PDM1\HRCS_constraint.sql **/
