/**Begin D:\d_desk\pdm\PDM_UPGRADE_1.1\PDM_UPGRADE\pdm1\BDM_table.sql **/
 EXEC P_ALTERPK 'PK_T_BDM_FAIL_PUSH_SMS_EMAIL', 'T_BDM_FAIL_PUSH_SMS_EMAIL', 'FID', '0';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_BDM_FAIL_PUSH_SMS_EMAIL') CREATE  CLUSTERED INDEX IDX_BDM_FAIL_PUSH_SMS_EMAIL ON T_BDM_FAIL_PUSH_SMS_EMAIL ( FINVOICECODE ,FINVOICENO );

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_BDM_FAIL_PUSH_SMS_EMAIL2') CREATE INDEX IDX_BDM_FAIL_PUSH_SMS_EMAIL2 ON T_BDM_FAIL_PUSH_SMS_EMAIL ( FINVOICEID,FTYPE );

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_BDM_FAIL_PUSH_SMS_EMAIL3') CREATE INDEX IDX_BDM_FAIL_PUSH_SMS_EMAIL3 ON T_BDM_FAIL_PUSH_SMS_EMAIL ( FSTATUS,FSENDTIMES );

/**End D:\d_desk\pdm\PDM_UPGRADE_1.1\PDM_UPGRADE\pdm1\BDM_table.sql **/
