From 94eeaaaa51566b9ad89f2cd3cfdf414a0243d0e5 Mon Sep 17 00:00:00 2001 From: Clemens Schwaighofer Date: Tue, 28 Mar 2023 16:49:06 +0900 Subject: [PATCH] DB\IO Debug output update for parameter queries --- src/DB/IO.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/DB/IO.php b/src/DB/IO.php index aa681ea..8f65159 100644 --- a/src/DB/IO.php +++ b/src/DB/IO.php @@ -892,7 +892,9 @@ class IO for ($i = 0, $iMax = count($keys); $i < $iMax; $i++) { $keys[$i] = '$' . ($keys[$i] + 1); // prefix data set with parameter pos - $data[$i] = $keys[$i] . ':' . $data[$i]; + $data[$i] = $keys[$i] . ':' . ($data[$i] === null ? + '"NULL"' : (string)$data[$i] + ); } // simply replace the $1, $2, ... with the actual data and return it return str_replace(