title: Most performant alternative to SELECT COUNT(*) using PDO and MySQL
body: <p>I've read previously that <code>SELECT COUNT(*)</code> is not performant in <code>MySQL</code> and should be regularly avoided. (As a side question, is this only the case for a large number of rows?)</p>
  
  <p>I'm using <code>PHP Data Objects (PDO)</code> to access <code>MySQL</code>.</p>
  
  <p>How should I be counting rows with performance considerations in mind?</p>