this is my code for deleteng data to database. even if i pass wrong "dataid" it still output good. i even checked the database if a data has been deleted but no row affected. but if i pass "dataid" a correct id. it deletes the data with that ID and returns good. so why else doesn't worked?
is it not the good way to check if statement executed correctly? the code im using is i found at this site. but it doesn't work for me, can someone help me thanks
$temp = $_POST['dataid'];
$stmt = $conn->prepare("CALL sp_deletesignatory (?)");
$stmt->bindParam(1, $temp, PDO::PARAM_STR, 10);
$value = $stmt->execute();
if($value){
echo "good";
}else{
echo "error";
}