title: Sql query for searching through firstName and lastName columns for all similar records
body: <p>I am working on to build a query in MYSQL by which I can search through firstName and lastName columns in table that can return all records that nearly matches it.</p>
  
  <p>Like I want to search a name say, <strong>Aditya Kumar Sharma</strong> and my table containes something like this:</p>
  
  <pre><code>ID    firstName        lastName
  1     Jack             Mathews
  2     Aditya           Singh
  3     James            Hopes
  4     Aditya Kumar     Sharma
  5     Adityahappy      Singh
  </code></pre>
  
  <p>Now I want all the records containing any of these <strong>Aditya</strong> or <strong>Kumar</strong> or <strong>Sharma</strong> in both firstName and lastName columns, which means I need following records in my resultset:</p>
  
  <pre><code>ID    firstName        lastName
  2     Aditya           Singh
  4     Aditya Kumar     Sharma
  5     Adityahappy      Singh
  </code></pre>
  
  <p>Can anyone provide me some clue, how to get it done. and it will be more pleasing if the most matching record comes on top, that is:</p>
  
  <pre><code>ID    firstName        lastName
  4     Aditya Kumar     Sharma
  </code></pre>
  
  <p>comes on top of resultset, as it is completely matching the query String.</p>
  
  <p><strong>EDIT :</strong> I am using InnoDB engine for my database so FullText do not work over that, is there any other way around or I am forced to switch my DB engine?</p>