title: Why is MySQL matching strings and integers in a way I don't expect?
body: <p>I have a mysql database with the following column:</p>
  
  <pre><code>    +-----+
      | vpn |
      +-----+
      | 11a |
  </code></pre>
  
  <p>When I use query:</p>
  
  <pre><code>SELECT vpn FROM vpn_map  WHERE vpn=11;
  </code></pre>
  
  <p>It returns:</p>
  
  <pre><code>    +-----+
      | vpn |
      +-----+
      | 11a |
  </code></pre>
  
  <p>But if I query:</p>
  
  <pre><code>Select VPN from vpn_map where vpn=lla;
  </code></pre>
  
  <p>I get:</p>
  
  <pre><code>ERROR 1054 (42S22): Unknown column '11a' in 'where clause'
  </code></pre>
  
  <p>Why doesn't the previous query match?  It will match if I do:</p>
  
  <pre><code>Select VPN from vpn_map where vpn='lla';
  </code></pre>
  
  <p>But then vpn='11' won't match anything.  What am I missing here?</p>