diff --git a/library/think/db/Connection.php b/library/think/db/Connection.php index f5182be4..6c2a0ce0 100644 --- a/library/think/db/Connection.php +++ b/library/think/db/Connection.php @@ -793,7 +793,7 @@ abstract class Connection } } else { // 未注册监听则记录到日志中 - Log::record('[ SQL ] ' . $this->queryStr . ' [ RunTime:' . $runtime . 's ]', 'sql'); + Log::record('[ SQL ] ' . $sql . ' [ RunTime:' . $runtime . 's ]', 'sql'); if (!empty($explain)) { Log::record('[ EXPLAIN : ' . var_export($explain, true) . ' ]', 'sql'); }