java.sql.SQLException: The server time zone value '�й���׼ʱ��' is unrecognized

idea数据库连接字符串需要添加一些参数;

?useUnicode=true&characterEncoding=UTF-8&serverTimezone=Asia/Shanghai

【完整的连接】

spring.datasource.url=jdbc:mysql://localhost:3306/mydb?useUnicode=true&characterEncoding=UTF-8&serverTimezone=Asia/Shanghai

【参考】

https://blog.csdn.net/qq_43371004/article/details/98385445?utm_medium=distribute.pc_relevant.none-task-blog-BlogCommendFromMachineLearnPai2-1.nonecase&depth_1-utm_source=distribute.pc_relevant.none-task-blog-BlogCommendFromMachineLearnPai2-1.nonecase

posted @ 2020-06-10 18:27  lishidefengchen  阅读(927)  评论(0编辑  收藏  举报