FUNCTION security.to_date does not exist

发布时间 2023-07-27 16:35:03作者: E-青稞

方法函数不存在

解决:oracle 中说明使用的to_date不存在或当前版本不支持,换成to_days就可以了

如果是mysql中,mysql并不支持to_date方法,所以需要改为str_to_date方法

 

或修改

select * from as_gen_plan_record t

where DATE_FORMAT(t.time, '%Y-%m-%d') >= DATE_FORMAT(:beginTime, '%Y-%m-%d')

and DATE_FORMAT(t.time, '%Y-%m-%d') < DATE_FORMAT(:endTime, '%Y-%m-%d')