title: Mysql count vs mysql SELECT, which one is faster?
body: <p>If I want to do a check a name, I want to see how many rows/name exists in the "username" column under users table. Lets say thousands ... hundred of thousands, should I use:</p>
  
  <ul>
  <li><p>count(name), </p></li>
  <li><p>count(*) or </p></li>
  <li><p>SELECT username FROM users where username = 'name'</p></li>
  </ul>
  
  <p>Which one is the more appropriate? Or they will give same result in term of speed/response?</p>
  
  <p>EDIT:</p>
  
  <p>Thanks guys, I found the answer, count() will definitely faster</p>
  
  <p>Is this query correct</p>
  
  <pre><code>SELECT COUNT( username )
  FROM users
  WHERE `username` = 'tim' 
  </code></pre>