From 6331c5284923714a3fd60e34af1ec3564f7d885f Mon Sep 17 00:00:00 2001 From: forecho Date: Thu, 10 Mar 2016 15:29:04 +0800 Subject: [PATCH] fix bug MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 备份出来的 SQL 是一个分号 --- helpers/MysqlBackup.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/helpers/MysqlBackup.php b/helpers/MysqlBackup.php index bfd654e..2242cae 100644 --- a/helpers/MysqlBackup.php +++ b/helpers/MysqlBackup.php @@ -93,7 +93,7 @@ public function getData($tableName) $valueString = "('" . $valueString . "'),"; $values = "\n" . $valueString; if ($values != "") { - $data_string .= "INSERT INTO `$tableName` (`$items`) VALUES" . rtrim($values, ",") . ";;;" . PHP_EOL; + $data_string .= "INSERT INTO `$tableName` (`$items`) VALUES" . rtrim($values, ",") . ";" . PHP_EOL; } } @@ -162,4 +162,4 @@ public function writeComment($string) fwrite($this->fp, '-- -------------------------------------------' . PHP_EOL); } -} \ No newline at end of file +}