测试的时候报错:
Caused by: 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 .....
将
<property name="connection.url">jdbc:mysql://localhost:3306/hibernatetest</property>
修改为
<property name="connection.url">jdbc:mysql://localhost:3306/hibernatetest?serverTimezone=UTC</property>
本文介绍了一种常见的MySQL连接异常问题,即服务器返回的时区值不被识别或存在歧义,导致应用程序无法正常启动。解决方案是通过在连接字符串中指定具体的时区参数来规避此问题。
9932

被折叠的 条评论
为什么被折叠?



