date format picture ends before converting entire input string
文章目录
向oracle数据表中插入记录时报错:
ORA-01858: date format picture ends before converting entire input string插入失败的sql语句:
insert into user_baseinfo(id, end_date)
values(1, to_date('2020-01-01 01:01:01.000', 'yyyy-MM-dd'));原因分析:
传入的日期格式和给定的格式不对应
修改之后的sql,成功插入表中
insert into user_baseinfo(id, end_date)
values(1, to_date('2020-01-01', 'yyyy-MM-dd'));
评论
登录后参与技术讨论,分享你的经验与见解。
登录 / 注册暂无评论