导入数据库备份返回#1064

时间:2013-09-30 13:05:41

标签: mysql database phpmyadmin export

突然导入数据库备份会返回以下错误。 奇怪的是导入一个旧的工作副本它的工作原理。 如果我之后直接导出它并尝试重新导入它,则文件会出现此错误。

看起来它是导致问题的PhpMyAdmin导出。 我不知道PhpMyAdmin导出过程是否有任何变化?

This看起来像我的问题,但解决方案对我不起作用。

There is a chance that you may have found a bug in the SQL parser. 
Please examine your query closely, and check that the quotes are 
correct and not mis-matched. Other possible failure causes may be 
that you are uploading a file with binary outside of a quoted text 
area. You can also try your query on the MySQL command line interface. 
The MySQL server error output below, if there is any, may also 
help you in diagnosing the problem. If you still have problems or 
if the parser fails where the command line interface succeeds, please 
reduce your SQL query input to the single query that causes problems, 
and submit a bug report with the data chunk in the CUT section below:

----INIZIO CUT----
eNo1jU0KwjAYRIXuvlPMAWIw0SrNLoTQLvJn0roXF1IQ3Sjo7U0FZ/UYHjM255gVjICRcDYoCEgI
QWWsdUPkP+XoFFou+L5b3x5XmkpGLAy6t2FkONkq+vMFZsjR22puuOwoea2wq9xSGtJisViWnS0X
B7j5/nqT06FXmJ/0u6Bm9c8XSs4hPQ==
----FINE CUT----

----INIZIO RAW----
ERROR: C1 C2 LEN: 1 2 11
STR: MySQL: 5.1.69-log
USR OS, AGENT, VER: Mac CHROME 5.0.29
PMA: 4.0.5
PHP VER,OS: 5.3.17 Linux
LANG: it
SQL: 

----FINE RAW----



Query SQL:

Messaggio di MySQL: 
#1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1

(我在错误中翻译了我的错误,因为我的phpmyadmin是意大利语)

2 个答案:

答案 0 :(得分:3)

我有同样的问题,我找到了解决方案。使用任何代码编辑器打开sql文档,在最后一行的最后,你会看到一些黑色奇怪的代码只是删除,保存应该可以正常工作。

我不确定导出数据库时生成此代码的方式和原因。

答案 1 :(得分:1)

您正在运行过时的phpMyAdmin版本。我相信在https://sourceforge.net/p/phpmyadmin/bugs/4095/(即将推出的4.0.8版本)中提到的修复将对您有所帮助。

直接链接到修复程序(可应用于4.0.7):https://github.com/phpmyadmin/phpmyadmin/commit/b717657de77db0b58179bdbdd88e23d0fc3d7ea6

相关问题