title: mysql_num_rows returns null every time
body: <pre><code>if (isset($_GET["val"])) {
      $val = $_GET["val"];
      $sql1 = "select count(*) as count from staff_log l where l.time_in is null and l.time_out is not null and l.date_today = curdate() and l.staff_id = ".$val.";";
  
      $result1 = mysql_num_rows($sql1);
  }
  </code></pre>