mirror of
https://gitee.com/fastadminnet/framework.git
synced 2026-07-01 12:42:48 +08:00
改进Connection类的getRealSql方法
This commit is contained in:
@@ -478,8 +478,8 @@ abstract class Connection
|
||||
$sql = is_numeric($key) ?
|
||||
substr_replace($sql, $value, strpos($sql, '?'), 1) :
|
||||
str_replace(
|
||||
[':' . $key . ')', ':' . $key . ',', ':' . $key . ' '],
|
||||
[$value . ')', $value . ',', $value . ' '],
|
||||
[':' . $key . ')', ':' . $key . ',', ':' . $key . ' ', ':' . $key . PHP_EOL],
|
||||
[$value . ')', $value . ',', $value . ' ', $value . PHP_EOL],
|
||||
$sql . ' ');
|
||||
}
|
||||
return rtrim($sql);
|
||||
|
||||
Reference in New Issue
Block a user