title: Select all records from table A, even if one or more of it's ID(i.e FK) not present in table B
body: <p>First of all, I know heading sounds a bit confusing and I am sorry for that. I couldn't find words to articulate myself exactly in a sentence.</p>
  
  <p>So here is what I am trying to do :</p>
  
  <p>A simple search box where user types in a name and gets autosuggestion like in google. </p>
  
  <p>My first table('users') is like this :</p>
  
  <pre><code>  Table 'users':
  
     Id(PK)     name   email
      10        max    max@max.com
      20        john   john@john.com
      30        jack   jack@jack.com
      40        jill   jill@jill.com
  </code></pre>
  
  <p>And second table('pictures') like this :</p>
  
  <pre><code>  Table 'pictures':
  
     Id    user_id(FK)   profilepic          iscurrent
      1    10            abc.jpg             1
      2    20            sds.jpg             0
      3    30            asdasd.jpg          1
      4    20            sdsdff.jpg          1
  </code></pre>
  
  <p>Now when users start typing name say <code>"joh"</code>, he will see <code>"john + john's email + john's picture"</code> in suggestions .</p>
  
  <p>This is how I am implementing it now :</p>
  
  <pre><code>SELECT users.name, users.email, pictures.profilepic
  FROM pictures 
  INNER JOIN users 
  ON pictures.user_id=users.id 
  WHERE pictures.is_current = 1 
  AND users.name LIKE '%joh%' OR email LIKE '%joh%' 
  ORDER BY users.id 
  ASC LIMIT 5;
  </code></pre>
  
  <p>The problem is that it selects only records which have a FK in second table('pictures') </p>
  
  <p>but I want users to see all records matching the name they entered even if that user doesn't have a profile picture .</p>
  
  <p>Hope you've understood the problem.
  Thanks in advance.</p>