title: is fastest a complex LIKE on a single field or a WHERE using "=" on multiple fields?
body: <h2>General question</h2>
  <p>In general, question is: <em>is a complex LIKE on a single field faster than a WHERE using &quot;=&quot; on multiple fields</em> ?</p>
  <p>which is the fastest query having more than 100M of records?</p>
  <p>1st option:</p>
  <pre><code>SELECT * from codes WHERE code LIKE &quot;_A__9_2__&quot; 
  </code></pre>
  <p>2nd option:</p>
  <pre><code>SELECT * from codes WHERE char_2 = &quot;A&quot; AND char_5 = &quot;9&quot; and char_7= &quot;2&quot;
  </code></pre>
  <h2>Context</h2>
  <p>We have a sw generating more than 100M of fixed length string (9 chars for precision)
  We <em>must</em> do tons, really tons, it's the goal of sw, of queries using only 1 to 9 chars</p>
  <p>I think the only tradeoff of 2nd way is that, indexing every single fields to optimize lookup speed, It will multiply the data a lot.</p>
  <p>But, while I think 2nd way it's better, I've not idea if it's really faster as I suppose</p>