The server time zone value '�й���׼ʱ��' is unrecognized...mysql报错

The server time zone value ‘�й���׼ʱ��’ is unrecognized…mysql报错

配置文件yml中:
The server time zone value '�й���׼ʱ��' is unrecognized...mysql报错_第1张图片

spring:
  datasource:
    url: jdbc:mysql://localhost:3306/xy-v1?serverTimezone=UTC
    driver-class-name: com.mysql.cj.jdbc.Driver
    username: root
    password: 87683256

在url后加上serverTimezone=UTC即可解决。

你可能感兴趣的:(爬坑记录,java,mysql)