在springboot项目中,由于使用了高版本的mysql驱动(6.0+以后)就会出现需要设置时区的问题
jdbc.url改一下就行了,中国为东八区
spring.datasource.url=jdbc:mysql://localhost:33066/test?useUnicode=true&characterEncodeing=UTF-8&useSSL=false&serverTimezone=GMT%2B8
© 著作权归作者所有
举报
相关热门文章
发表评论
0/200
spring.datasource.url=jdbc:mysql://localhost:33066/test?useUnicode=true&characterEncodeing=UTF-8&useSSL=false&serverTimezone=GMT%2B8
© 著作权归作者所有
发表评论