/**Begin D:\work\kuaijishijian\pdm\PDM_UPGRADE_1.4\PDM_UPGRADE\PDM1\AI_constraint.sql **/
 EXEC P_ALTERPK 'PK_FAH_XLA_MERGE_CUSTFLDS', 'T_FAH_XLA_MERGE_CUSTFLDS', 'FENTRYID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_TABNAME = 'T_FAH_XLA_MERGE_CUSTFLDS' AND KSQL_INDNAME = 'IDX_FAH_XLA_MERGE_CUSTFLDS') CREATE INDEX IDX_FAH_XLA_MERGE_CUSTFLDS ON T_FAH_XLA_MERGE_CUSTFLDS ( FID );


 EXEC P_ALTERPK 'PK_FAH_XLA_MERGE_RULE', 'T_FAH_XLA_MERGE_RULE', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_TABNAME = 'T_FAH_XLA_MERGE_RULE' AND KSQL_INDNAME = 'IDX_FAH_XLA_MERGE_RULE') CREATE INDEX IDX_FAH_XLA_MERGE_RULE ON T_FAH_XLA_MERGE_RULE ( FNUMBER );


 EXEC P_ALTERPK 'PK_FAH_XLA_VCH_REWRTRULE', 'T_FAH_XLA_VCH_REWRTRULE', 'FENTRYID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_TABNAME = 'T_FAH_XLA_VCH_REWRTRULE' AND KSQL_INDNAME = 'IDX_FAH_XLA_VCH_REWRTRULE') CREATE INDEX IDX_FAH_XLA_VCH_REWRTRULE ON T_FAH_XLA_VCH_REWRTRULE ( FID );


 EXEC P_ALTERPK 'PK_FAH_XLA_MERGE_RULE_L', 'T_FAH_XLA_MERGE_RULE_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_TABNAME = 'T_FAH_XLA_MERGE_RULE_L' AND KSQL_INDNAME = 'IDX_FAH_XLA_MERGE_RULE_L') CREATE INDEX IDX_FAH_XLA_MERGE_RULE_L ON T_FAH_XLA_MERGE_RULE_L ( FID ,FLOCALEID );



/**End D:\work\kuaijishijian\pdm\PDM_UPGRADE_1.4\PDM_UPGRADE\PDM1\AI_constraint.sql **/
