/**Begin D:\pdm\PDM_UPGRADE\pdm_new\RIM_constraint.sql **/
 EXEC P_ALTERPK 'PK_RIM_INVSIGN_LOG', 'T_RIM_INVSIGN_LOG', 'FID', '0';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_RIM_INVSIGN_LOG') CREATE  CLUSTERED INDEX IDX_RIM_INVSIGN_LOG ON T_RIM_INVSIGN_LOG ( FCREATEDATE );

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_RIM_INVSIGN_LOG2') CREATE INDEX IDX_RIM_INVSIGN_LOG2 ON T_RIM_INVSIGN_LOG ( FBATCH );

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_RIM_INVSIGN_LOG3') CREATE INDEX IDX_RIM_INVSIGN_LOG3 ON T_RIM_INVSIGN_LOG ( FEXPENSE_NUM );


 EXEC P_ALTERPK 'PK_RIM_INVSIGN_LOG_ITEM', 'T_RIM_INVSIGN_LOG_ITEM', 'FENTRYID', '0';

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



/**End D:\pdm\PDM_UPGRADE\pdm_new\RIM_constraint.sql **/
