crx349 发表于 2022-7-11 03:10:58

Discuz!x3.4 Mysql8 兼容解决方案

discuz!x3.4 再mysql8下安装会出现
Error: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 'admin char(15) NOT NULL default '0' ... 错误
解决方法:
#centos 7或8下ssh下 文件批量替换 sql安装文件(注意sql文件路径)
sed -ri 's/ {2}(+)/`\1\`/g' install/data/install.sql uc_server/install/uc.sql


这时候再运行安装程序,就可以正常安装discuz了
页: [1]
查看完整版本: Discuz!x3.4 Mysql8 兼容解决方案