最近在写项目数据导入的过程中遇到这样一个错误信息:

java.sql.SQLException: Value ‘0000-00-00 00:00:00’ can not be represented as java.sql.Timestamp

'0000-00-00 00:00:00' can not be represented as java.sql.Timestamp问题的解决
然后查看了数据表,时间字段类型为时间戳,默认为:0000-00-00 00:00:00,但是它在后台查询出现此错误,不能够转换这种格式,于是找度娘各种搜:一种最有效的方法就是如下:
在数据库链接的URL地址上:加上: &zeroDateTimeBehavior=convertToNull &zeroDateTimeBehavior=convertToNull
'0000-00-00 00:00:00' can not be represented as java.sql.Timestamp问题的解决
&有些可能要替换成&
到此就可以去安心做其他事了。。。。记得给亲点个赞哦!!!!!

相关文章:

  • 2021-09-16
  • 2022-12-23
  • 2021-08-08
  • 2021-05-21
  • 2021-08-22
  • 2022-12-23
  • 2022-12-23
  • 2021-10-21
猜你喜欢
  • 2021-04-19
  • 2021-07-17
  • 2022-03-04
  • 2022-12-23
  • 2021-08-11
相关资源
相似解决方案