Value '0000-00-00 00:00:00' can not be represented as java.sql.Timestamp 报错
如果报错 Value '0000-00-00 00:00:00' can not be represented as java.sql.Timestamp 是因为 jdbc默认最小时间 为 0001-01-01 00:00:00 所以转换为 sql timestamp 失败 解决办法 在连接数据库的url中加入&zeroDateTimeBehavior=convertToNull 类似 jdbc:mysql:///seckill?useUnicode=true&zeroDateTimeBehavior=convertToNull&characterEncoding=utf-8