title: PDO fetch() error
body: <p>Here's my code:</p>
  
  <pre><code>    $qer="insert into users (user,first,last,bio,email,pass,date,bd) values ('$name','$first','$last','$bio','$email','$pass','$date','$bd')";
  $query=$con-&gt;query("select * from 'users'");
  while($row=$query-&gt;fetch(PDO::FETCH_ASSOC)){
      echo $row['user'];
  }
  </code></pre>
  
  <p>And here's my error:</p>
  
  <pre><code>Fatal error: Call to a member function fetch() on a non-object in /opt/lampp/htdocs/it/newuser.php on line 97
  </code></pre>
  
  <p>Line 97 is the while statement, of course.</p>
  
  <p>I'm not sure why it thinks it's not handling an object... or why I think it is. Help is appreciated. Thank you!</p>