/**Begin D:\PDM_UPGRADE\PDM1\HRSS_constraint.sql **/
 EXEC P_ALTERPK 'PK_HRSS_SEARCHSCENE', 'T_HRSS_SEARCHSCENE', 'FID', '1';

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


 EXEC P_ALTERPK 'PK_HRSS_SEARCHSCENE_L', 'T_HRSS_SEARCHSCENE_L', 'FPKID', '1';

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


 EXEC P_ALTERPK 'PK_HRSS_SCENEENTRYENTITY', 'T_HRSS_SCENEENTRYENTITY', 'FENTRYID', '1';

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


 EXEC P_ALTERPK 'PK_HRSS_SEARCHWTGRADE', 'T_HRSS_SEARCHWTGRADE', 'FID', '1';

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


 EXEC P_ALTERPK 'PK_HRSS_SEARCHWTGRADE_L', 'T_HRSS_SEARCHWTGRADE_L', 'FPKID', '1';

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


 EXEC P_ALTERPK 'PK_HRSS_SEARCHWGENTRY', 'T_HRSS_SEARCHWGENTRY', 'FENTRYID', '1';

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


 EXEC P_ALTERPK 'PK_HRSS_SEARCHWGENTRY_L', 'T_HRSS_SEARCHWGENTRY_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_HRSS_SEARCHWGENTRY_L') CREATE INDEX IDX_HRSS_SEARCHWGENTRY_L ON T_HRSS_SEARCHWGENTRY_L ( FLOCALEID ,FENTRYID );


 EXEC P_ALTERPK 'PK_HRSS_AIWORDCATEGORY', 'T_HRSS_AIWORDCATEGORY', 'FID', '1';

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


 EXEC P_ALTERPK 'PK_HRSS_AIWORDCATEGORY_L', 'T_HRSS_AIWORDCATEGORY_L', 'FPKID', '1';

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


 EXEC P_ALTERPK 'PK_HRSS_SEARCHWEIGHT', 'T_HRSS_SEARCHWEIGHT', 'FID', '1';

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


 EXEC P_ALTERPK 'PK_HRSS_SEARCHWEIGHT_L', 'T_HRSS_SEARCHWEIGHT_L', 'FPKID', '1';

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


 EXEC P_ALTERPK 'PK_HRSS_SEARCHWTENTRYS', 'T_HRSS_SEARCHWTENTRYS', 'FENTRYID', '1';

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



/**End D:\PDM_UPGRADE\PDM1\HRSS_constraint.sql **/
