diff --git a/MysqliDb.php b/MysqliDb.php index 02cf2ec9..7e56c47d 100644 --- a/MysqliDb.php +++ b/MysqliDb.php @@ -2042,6 +2042,9 @@ protected function replacePlaceHolders($str, $vals) } if ($val === null) { $val = 'NULL'; + $newStr .= substr($str, 0, $pos) . $val; + }else{ + $newStr .= substr($str, 0, $pos) . "'" . $val . "'"; } $newStr .= substr($str, 0, $pos) . "'" . $val . "'"; $str = substr($str, $pos + 1);