From 02595c8350070c82208afe0217b965e3725c3a87 Mon Sep 17 00:00:00 2001 From: cbwfree Date: Tue, 14 Jun 2016 16:24:52 +0800 Subject: [PATCH] =?UTF-8?q?Query=20=E7=9A=84=20delete()=20=E6=96=B9?= =?UTF-8?q?=E6=B3=95=E4=BD=BF=E7=94=A8=20fetchSql()=20=E6=8A=A5=E9=94=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 原代码第 `1976` 行 `$this->getRealSql($sql,$this->bind);` 应该修改为 `$this->connection->getRealSql($sql,$this->bind);` --- library/think/db/Query.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/library/think/db/Query.php b/library/think/db/Query.php index fa771afc..566d5446 100644 --- a/library/think/db/Query.php +++ b/library/think/db/Query.php @@ -1973,7 +1973,7 @@ class Query $sql = $this->builder()->delete($options); if($options['fetch_sql']){ // 获取实际执行的SQL语句 - return $this->getRealSql($sql,$this->bind); + return $this->connection->getRealSql($sql,$this->bind); } // 执行操作 return $this->execute($sql, $this->getBind());