0

I have the following mysql query executed --

$stmt = $linkID1->prepare("select fstatus from cae_friends where provider_email=? and request_email=?");
$stmt->bind_param("ss", $uid,$row['email']);
$stmt->execute();
$stmt->bind_result($fstatus);
$stmt->fetch();
$stmt->close();

Now how do I determine whether my query returned any reslutset or its empty. Kindly help

Fabian N.
  • 1,188
  • 9
  • 18

1 Answers1

0

Finally i got the solution, may be its not the smarter way, but my purpose is solved. I changed the query as --

$stmt = $linkID1->prepare("select count(fstatus),fstatus from cae_friends where provider_email=? and request_email=?");
                            $stmt->bind_param("ss", $uid,$row['email']);
                            $stmt->execute();
                            $stmt->bind_result($val,$fstatus);
                            $stmt->fetch();


                            echo "Row Count : ".$val;

Now $val is giving out the right output. Thanks guys