当前位置:Gxlcms > 数据库问题 > 部署mysql版本项目问题记录

部署mysql版本项目问题记录

时间:2021-07-01 10:21:17 帮助过:12人阅读

一,com.mysql.cj.jdbc.exceptions.CommunicationsException: Communications link failure报错

将url从jdbc:mysql://localhost:3306/datashare?useUnicode=true&characterEncoding=utf-8&useSSL=true改为

jdbc:mysql://localhost:3306/datashare?autoReconnect=true&useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=CONVERT_TO_NULL&useSSL=false&serverTimezone=UTC

二,The connection property ‘zeroDateTimeBehavior‘ only accepts values of the form: ‘exception‘, ‘round‘ or ‘convertToNull‘. The value ‘CONVERT_TO_NULL‘ is not in this set.报错

具体信息为:

The connection property ‘zeroDateTimeBehavior‘ only accepts values of the form: ‘exception‘, ‘round‘ or ‘convertToNull‘. The value ‘convertToNull ‘ is not in this set.

将zeroDateTimeBehavior=CONVERT_TO_NULL改为zeroDateTimeBehavior=convertToNull 

三,mysql查询时表名大写的时候报错Table ‘datashare.TEST‘ doesn‘t exist

用 root 登录,修改 /etc/my.cnf (注意:以实际 my.cnf 配置文件路径为准)
在 [mysqld] 节点下,加入一行: lower_case_table_names=1(0:大小写敏感;1:大小写不敏感)

重启 MySQL 即可;

部署mysql版本项目问题记录

标签:mes   values   his   cal   tab   mysq   har   property   test   

人气教程排行