title: SQL View which returns value or null if not found
body: <p>I don't think this can be done but as I am a bit of a rookie using MSSM studio for a SQL database I thought I'd ask anyway.</p>
  
  <p>I have 2 tables and use a view to see matching records. Table 2 sometimes doesn't have matching records so naturally they won't show in my view. For example:</p>
  
  <pre><code>A-1
  B-2
  C-3
  </code></pre>
  
  <p>What I really need is for the view to show me the contents for the matching records in Table 2 but at the same time show me that nothing was found for the others:</p>
  
  <pre><code>A-1
  B-2
  C-3
  D-"Not Found"
  E-"Not Found"
  </code></pre>
  
  <p>This way I can prepare my view exactly as I need it but can go through the ones that aren't found in table 2. Hopefully someone can help me find a way to get this done. Thanks in advance.</p>
  
  <p>--------EDIT----------</p>
  
  <p>OK so the first table (GoogleBusinessData) holds.amongst other things, clients websites. The second table (EmailTable) holds a number of email addresses. The common link is the BusWebsite column. </p>
  
  <pre><code>SELECT dbo.GoogleBusinessData.BusWebsite, dbo.EmailTable.EmailNumberOfEmails
  FROM   dbo.GoogleBusinessData 
  INNER JOIN dbo.EmailTable ON dbo.GoogleBusinessData.BusWebsite = dbo.EmailTable.EmailWebsite
  </code></pre>
  
  <p>The problem here is that it will list the emails that appear when the websites match, but I would love to be able to list all of my data from dbo.GoogleBusinessData.BusWebsite, and if it is matched with EmailTable.EmailWebsite then it would display the number in dbo.EmailTable.EmailNumberOfEmails, but if it's not found then display "Not Found".</p>