try to add query to an existing repository, but fails