首页 > 技术文章 > MySQL连接数据库时区错误

colayc 2021-01-15 19:09 原文

### Error querying database. Cause: 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.

 

 

最直接的方法,在连接数据库代码的url后面添加:

?serverTimezone=GMT

如图:

 

推荐阅读