update batch update function