com.mysql.cj.exceptions.InvalidConnectionAttributeException: The server time zone value '�й���׼ʱ��' is unrecognized or represents more than one time zone.

主要是配置mysql数据库的时候没有配置时区,修改:

jdbc:mysql://localhost:3306/auto_test?serverTimezone=UTC&useUnicode=true&characterEncoding=utf-8

serverTimezone=GMT%2B8 (格林尼治标准时间,曾是世界时)

也可以设置成其它时区如UTC(协调世界时,现作为世界标准时间使用)

猜你喜欢

转载自www.cnblogs.com/saifei1125/p/12187258.html