title: Using Two Columns in SQL INNER JOIN
body: <p>TableA</p>
  
  <pre><code>AID     AName
  1       Alpha
  2       Bravo
  3       Charlie
  </code></pre>
  
  <p>TableB</p>
  
  <pre><code>BID     BName
  1       Delta
  2       Echo
  3       Foxtrot
  </code></pre>
  
  <p>TableC</p>
  
  <pre><code>CID     AID     BID
  1       1       null
  2       null    2
  3       3       null
  </code></pre>
  
  <p>I am using the following SQL statement:</p>
  
  <pre><code>SELECT C.CID, A.Name AS First, B.Name AS Second FROM TableC 
  INNER JOIN TableA ON TableC.AID = TableA.AID
  INNER JOIN TableB ON TableC.BID = TableB.BID
  </code></pre>
  
  <p>but displays a blank record. The expected result should be:</p>
  
  <pre><code>CID     First     Second
  1       Alpha
  2                 Echo
  3       Charlie
  </code></pre>
  
  <p>Any suggestions?</p>