一、问题现象
启动java gradle项目jdbc时报错: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.
二、 原因定位:时区错误
三、修复方案
1、连接mysql服务,管理员身份,输入查询时区命令:show variables like "%time_zone%";
2、设置时区:set global time_zone="+8:00";
3、重新运行脚本成功