update for query