首页 > 其他 > 详细

The server time zone value 'Öйú±ê׼ʱ¼ä' is unrecognized or represents more than one time zone.

时间:2019-05-04 17:47:33      阅读:142      评论:0      收藏:0      [点我收藏+]

问题背景:
在Java中使用JDBC操作数据库,该数据库版本为8.0.15属于高版本(如果是低版本的话,通常是不会出现这些问题的)

详细错误信息如下:

java.sql.SQLException: The server time zone value Öйú±ê׼ʱ¼ä is unrecognized or represents more than one time zone. You must configure either the server or JDBC driver (via the serverTimezone configuration property) to use a more specifc time zone value if you want to utilize time zone support.

这个问题的原因是市区问题。

解决办法:
在jdbc对应的url加上serverTimezone=UTC即可解决,例如jdbc:mysql://localhost:3308/mysql?serverTimezone=UTC

The server time zone value 'Öйú±ê׼ʱ¼ä' is unrecognized or represents more than one time zone.

原文:https://www.cnblogs.com/youcong/p/10809087.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!