做这个查询,oracle数据库,我写的能预览,但不能筛选,时间那一列名叫A.Transaction_TIME
${if(len(starttime) == 0,"","and A.Transaction_TIME >= ('" +starttime+ "')")}
${if(len(endtime) == 0,"","and A.Transaction_TIME <= ('" +endtime+ "')")}
时间格式为年月日,时分秒
多了括号
参考下面的写法
${if(len(starttime) == 0,"","and A.Transaction_TIME >= '" +starttime+ "'")}
${if(len(endtime) == 0,"","and A.Transaction_TIME <= '" +endtime+ "'")}
==============
改成个下面的格式试试
${if(len(starttime) == 0,"","and to_char(A.Transaction_TIME,'yyyy-mm-dd') >= '" +starttime+ "'")}
${if(len(endtime) == 0,"","and to_char(A.Transaction_TIME,'yyyy-mm-dd') <= '" +endtime+ "'")}