Add a new query.