/**Begin E:\NextERP_PDM\PDM_UPGRADE\PDMS\branch_lastest\pdm\AR_constraint.sql **/
 EXEC P_ALTERPK 'PK_T_AR_ASPOLICYENTRY', 'T_AR_ASPOLICYENTRY', 'FENTRYID', '1';

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


 EXEC P_ALTERPK 'PK_T_AR_FINARBILL_E', 'T_AR_FINARBILL_E', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_AR_FIN_E_CAUSE') CREATE INDEX IDX_AR_FIN_E_CAUSE ON T_AR_FINARBILL_E ( FBADDEBTCAUSE );



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