错误:Value \'0000-00-00 00:00:00\' can not be represented as java.sql.Timestamp;的解决
来源:互联网 发布:mac文字游戏制作软件 编辑:程序博客网 时间:2024/06/06 12:55
问题:
代码中查询MySQL的结果集时报错,提示Value '0000-00-00 00:00:00' can not be represented as java.sql.Timestamp;刚开始以为是代码中格式化结果集中的日期报错,找了一遍发现并没有对日期进行格式化,发现是查询的结果集中某数据行的日期值为0000-00-00 00:00:00。因MySQL的时间类型datetime范围是1000-01-01 00:00:00 到 9999-12-31 23:59:59,所以报错。
解决方法:
将日期改为正常日期即可。
阅读全文
0 0
- 错误: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;的解决
- Value '0000-00-00' can not be represented as java.sql.Timestamp错误
- MySQL 关于 Value '0000-00-00 00:00:00' can not be represented as java.sql.Timestamp 的错误
- Err:java.sql.SQLException: Value '0000-00-00' can not be represented as java.sql.Timestamp
- [DEBUG] “java.sql.SQLException: Value '0000-00-00' can not be represented as java.sql.Timestamp”
- java.sql.SQLException: Value '0000-00-00' can not be represented as java.sql.Timestamp
- “java.sql.SQLException: Value '0000-00-00' can not be represented as java.sql.Timestamp”
- 解决:java.sql.SQLException: Value '0000-00-00 00:00:00' can not be represented as java.sql.Timestamp
- java 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
- Value '0000-00-00 00:00:00' can not be represented as java.sql.Timestamp
- ERROR: 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
- 提示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
- Value '0000-00-00' can not be represented as java.sql.Timestamp
- mysql Value '0000-00-00' can not be represented as java.sql.Timestamp
- 动态规划学习笔记
- 两层c:forEach循环嵌套
- MyEclipce中的jdk问题
- JQuery实现动态数据二级联动
- tf.nn has no attribute rnn_cell in version 1.0.1
- 错误:Value \'0000-00-00 00:00:00\' can not be represented as java.sql.Timestamp;的解决
- Mysql在delete时不支持别名?
- mapreduce 二次排序
- (伪优化)解决菜单(Menu)添加Icon无效问题/Android
- textarea没有value属性
- 根据单选按钮判断用户类型
- NNFS--Neural Network from Scratch
- mysql 连接url中useUnicode=true&characterEncoding=UTF-8 的作用
- 原生javascript 表单同步提交和提交前操作 和 document.form.submit() is not a function