title: Comparing two columns, and returning a specific adjacent cell in Excel
body: <p>I am using a combination of <code>if</code>, <code>vlookup</code>, <code>match</code>, <code>iserror</code> functions, and unfortunately I've not been able to find the right formula.</p>
  
  <p>Comparing two columns for matches is easy enough. the tough part has been returning a specific cell once a match is found.</p>
  
  <p>So what I'm dealing with is something kind of like this:</p>
  
  <pre><code>Header     Column A   Column B   Column C  Column D
  Row 1      111        AAA        112
  Row 2      222        BBB        111
  Row 3      333        CCC        221
  Row 4      444        DDD        333
  </code></pre>
  
  <p>I'm trying to  match column values in <code>Column A</code>, with <code>Column C</code>. So if there's match, I want the corresponding value in <code>Column B</code> to populate in <code>Column D</code>. Not a great explanation, but allow me to visually show you what I'm looking for</p>
  
  <pre><code>Header     Column A   Column B   Column C  Column D
  Row 2      111        AAA        112
  Row 3      222        BBB        111       AAA
  Row 4      333        CCC        221
  Row 5      444        DDD        333       CCC
  </code></pre>
  
  <p>Since Cells <code>A1</code> matches cell <code>C3</code>, I want <code>D</code> to return <code>B2</code></p>
  
  <p>Same with Row <code>5</code>. Since <code>A4</code> and <code>C5</code> match, I want the value for <code>B5</code></p>
  
  <p>Let me know if this makes sense or if you need further clarification.</p>