-- 租赁二期相关表索引
/**Begin E:\NextERP_PDM\PDM_UPGRADE\PDMS\branch_lastest\pdm\FA_constraint.sql **/
 EXEC P_ALTERPK 'PK_T_FA_LEASE_CONTRACT_NEW', 'T_FA_LEASE_CONTRACT_NEW', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_FA_CONTRACT_NEW_ORGDATE') CREATE INDEX IDX_FA_CONTRACT_NEW_ORGDATE ON T_FA_LEASE_CONTRACT_NEW ( FORGID ,FLEASESTARTDATE );


 EXEC P_ALTERPK 'PK_T_FA_LEASE_CONTRACT_NEW_L', 'T_FA_LEASE_CONTRACT_NEW_L', 'FPKID', '1';

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


 EXEC P_ALTERPK 'PK_T_FA_LEASE_PAY_RULE', 'T_FA_LEASE_PAY_RULE', 'FENTRYID', '1';

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



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