Cause: java.sql.SQLException: Conversion not supported for type java.time.LocalDateTime

Java 8 时间类型和MySQL时间类型转换错误

Error attempting to get column 'birth_date' from result set.  Cause: java.sql.SQLException: Conversion not supported for type java.time.LocalDateTime

 

解决方案:

升级MySQL驱动

<!--mysql 驱动依赖-->
<dependency>
    <groupId>mysql</groupId>
    <artifactId>mysql-connector-java</artifactId>
    <version>8.0.19</version>
</dependency>

 引入之后不要忘记刷新

 

 

官方解决方案

posted @ 2020-08-06 09:55  Cool_Yang  阅读(4034)  评论(0)    收藏  举报