your MySQL server version for the right syntax to use near '.`22`' at line 1

运行这个命令:php think optimize:schema数据库 生成缓存时 报错如下:


 SQLSTATE[42000]: Syntax error or access violation: 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 '.`22`' at line 1
]

错误原因:存在的个别数据表 有的名字 里面有.特殊符号不能识别,去掉即可;

例如:表名book2022.03.22.back有的框架可能不能正常识别改下名字即可:book2022-03-22back

文章来源:刘俊涛的博客 欢迎关注公众号、留言、评论,一起学习。


若有帮助到您,欢迎捐赠支持,您的支持是对我坚持最好的肯定(_)

posted @ 2022-04-01 17:19  刘俊涛的博客  阅读(0)  评论(0)    收藏  举报