存在的记忆

ubuntu18.04备份mysql数据库报ERROR 1064 (42000)错误


完整的bug信息:

ERROR 1064 (42000): 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 'mysqldump -uroot -p ylt>ylt.sql' at line 1

错误原因是我误以为mysqldum是sql命令,错误写入了mysql命令中

mysql> mysqldump -uroot -p ylt>ylt.sql;

后才发觉mysqldump是linux命令

遂退出mysql,在终端写入

[root@localhost ~]# mysqldump -uroot -p ylt>ylt.sql

这样就对了

当前页面是本站的「Baidu MIP」版。查看和发表评论请点击:完整版 »