/**Begin D:\d_desk\pdm\PDM_UPGRADE_1.1\PDM_UPGRADE\pdm1\BDM_constraint.sql **/
 EXEC P_ALTERPK 'PK_BDM_INV_ITEM_SETTING', 'T_BDM_INV_ITEM_SETTING', 'FID', '0';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_BDM_INV_ITEM_SETTING') CREATE  CLUSTERED INDEX IDX_BDM_INV_ITEM_SETTING ON T_BDM_INV_ITEM_SETTING ( FORG );


 EXEC P_ALTERPK 'PK_BDM_ISSUE_INV_SETTTTING', 'T_BDM_ISSUE_INV_SETTTTING', 'FID', '0';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_BDM_ISSUE_INV_SETTTING') CREATE  CLUSTERED INDEX IDX_BDM_ISSUE_INV_SETTTING ON T_BDM_ISSUE_INV_SETTTTING ( FORG );


 EXEC P_ALTERPK 'PK_BDM_SCANINVOICE_SETTING', 'T_BDM_SCANINVOICE_SETTING', 'FID', '0';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_BDM_SCANINVOICE_SETTING') CREATE  CLUSTERED INDEX IDX_BDM_SCANINVOICE_SETTING ON T_BDM_SCANINVOICE_SETTING ( FEQINFOTAXNO );


 EXEC P_ALTERPK 'PK_BDM_SYSTEM_SETTING', 'T_BDM_SYSTEM_SETTING', 'FID', '0';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_BDM_SYSTEM_SETTING') CREATE  CLUSTERED INDEX IDX_BDM_SYSTEM_SETTING ON T_BDM_SYSTEM_SETTING ( FTAXNO );



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