title: How to loop a vlookup inside an if statement?
body: <p>I am trying to create an if statement that returns true if a match is found in a reference table for the client name and the same service. However the vlookup only looks at the first client name (there are multiple records of the same client) and either returns a matching service or an error if the first service listed doesn't match. I need it to loop until it has looked at every instance of the client name to see if there is record of the client receiving that service. <a href="https://i.stack.imgur.com/UlJBc.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/UlJBc.png" alt="example worksheet" /></a></p>
  <p>My current formula would look something like this: <code>=IF(VLOOKUP(client name,reference table,service,FALSE) = service, &quot;Yes&quot;,&quot;No&quot;)</code></p>
  <p>How can this formula be changed to check every row for a match of the right client name and service?</p>