mysql 8
jdbc:mysql://127.0.0.1:3306/mydb?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&autoReconnect=true&useSSL=false&serverTimezone=GMT%2B0
serverTimezone=GMT%2B8
設定的東八區 北京時間
結果服務器在德國
代碼中涉及到時間戳轉換對比,怎么算都差8個小時,
所以連接mysql 資料庫的時候一定要修改時區,
轉載請註明出處,本文鏈接:https://www.uj5u.com/shujuku/228961.html
標籤:MySQL
下一篇:mysql 鏈接錯誤1251
