Py学习  »  DATABASE

Caused by: com.mysql.cj.exceptions.InvalidConne...

10676 • 4 年前 • 331 次点击  
Caused by: com.mysql.cj.exceptions.InvalidConnectionAttributeException: 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.
    at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)

解決方法 :
需要配置data-config.xml文件,在第6行url后添加“?serverTimezone=UTC”,如下所示:


image.png
?serverTimezone=UTC

?serverTimezone=Asia/shanghai
Python社区是高质量的Python/Django开发社区
本文地址:http://www.python88.com/topic/124558