better performance in update