/**Begin D:\d_desk\pdm\PDM_UPGRADE_1.1\PDM_UPGRADE\pdm1\BDM_constraint.sql **/
 EXEC P_ALTERPK 'PK_BDM_TERMINAL', 'T_BDM_TERMINAL', 'FENTRYID', '0';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_BDM_TERMINAL_FK') CREATE  CLUSTERED INDEX IDX_BDM_TERMINAL_FK ON T_BDM_TERMINAL ( FID );


 EXEC P_ALTERPK 'PK_BDM_TERMINAL_INVOICE', 'T_BDM_TERMINAL_INVOICE', 'FID', '0';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_BDM_TERMINAL_INVOICE_FK') CREATE  CLUSTERED INDEX IDX_BDM_TERMINAL_INVOICE_FK ON T_BDM_TERMINAL_INVOICE ( FSTARTNO );



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