/**Begin E:\NextERP_PDM\PDM_UPGRADE\PDMS\branch_lastest\pdm\BEI_constraint.sql **/
EXEC p_DropIdx 'IDX_BEI_ELECRECEIPT', 'T_BEI_ELECRECEIPT';
 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_BEI_ELECRECEIPT') CREATE INDEX IDX_BEI_ELECRECEIPT ON T_BEI_ELECRECEIPT ( FCOMPANYID ,FACCOUNTBANKID ,FCURRENCYID ,FBIZDATE ,FISMATCH );

EXEC p_DropIdx 'IDX_BALANCE_CACB', 'T_BEI_BANKBALANCE';
 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_BALANCE_CACB') CREATE UNIQUE INDEX IDX_BALANCE_CACB ON T_BEI_BANKBALANCE ( FCOMPANYID ,FACCOUNTBANKID ,FCURRENCYID ,FBIZDATE );

EXEC p_DropIdx 'IDX_BEI_TRANSDETAIL', 'T_BEI_TRANSDETAIL';
 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_BEI_TRANSDETAIL') CREATE  CLUSTERED INDEX IDX_BEI_TRANSDETAIL ON T_BEI_TRANSDETAIL ( FACCOUNTBANKID ,FBIZTYPE );


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