Here's the code:
$sql1 = "UPDATE muted_alerts SET `customer_id`=':customer_id', `sms_time` = '$fdate', `phone`=':phone'";
$stmt = $dbh->prepare($sql1, array(PDO::ATTR_CURSOR => PDO::CURSOR_FWDONLY) );
$stmt->execute(array(':phone' => $phone,':customer_id'=>$customer_id));
$result1 = $stmt->fetchAll(PDO::FETCH_ASSOC);
This throws no errors. I've used var_dump
to see if $phone
, $fdate
and $customer_id
are valid and they are.
I'm guessing there's a problem in my statement somehow. I excluded all the $dbh
lines for simplicity, but I have tested and know these are correct also.