title: Turning mysql query into prepared statement
body: <p>I'm trying to turn the below query into a prepared statement, but I'm having no luck so far. I've attached one of my attempts. The idea is I'm using this to check how many rows are returned using mysqli_num_rows afterward.</p>
  
  <pre><code> $sql2=mysqli_query($bd, "SELECT address FROM member WHERE address='".$address."'");
  </code></pre>
  
  <p>This is my attempt at creating a prepared statement.</p>
  
  <pre><code>$ustmt = $bd-&gt;prepare("SELECT username FROM member WHERE username = ?");
  $ustmt-&gt;bind_param("s", $username);
  $sql2 = $ustmt-&gt;execute();
  </code></pre>
  
  <p>Is this correct? And if so, how do I then check the number of rows returned into $sql2 ?</p>