Fixes for update_record and delete_record