server time zone value錯誤

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.

弄ibatis的時候報了個錯,主要報錯是上面的樣子。
猜測是時區問題server time zone value,畢竟直接提示了。
然後百度–》csdn,找到了解決方法 ?serverTimezone=UTC
在這裏插入圖片描述
問題解決。

ps:mysql的驅動問題在8點幾的版本後需要將驅動寫爲com.mysql.cj.jdbc.Driver

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章