title: PHP while loop loops everything except first query result
body: <p>I am struggling to understand why while loop not looping through the first query result.</p>
  
  <pre><code>$pdo = new PDO('connection');
  $stmt2 = $pdo-&gt;prepare("SELECT user FROM records
  ORDER BY date DESC");
  
  $stmt2-&gt;execute();
  $r2 = $stmt2-&gt;fetch(PDO::FETCH_ASSOC);
  
  while ($r2 = $stmt2-&gt;fetch(PDO::FETCH_ASSOC)) {
    echo '&lt;tr&gt;&lt;td&gt;' . $r1['user'] . '&lt;/td&gt;&lt;/tr&gt;';
  }
  </code></pre>
  
  <p>I've read <a href="https://stackoverflow.com/questions/37957127/while-loop-stuck-on-first-query-result">this</a> thread but it is OOP. Any suggestions?</p>