在使用Mybatis时,我遇到了SELECT DISTINCT Y.YARD_NAME
from MST_ACTUAL_CONSUMPTION A
INNER JOIN MST_VP_YARD Y ON Y.YARD_NAME=A.YARD_NO
where (TO_DATE(A.TO_DATE,'DD-MM-YYYY HH:MI') BETWEEN TO_DATE( substr('03-07-2018 00:00', 1, 10),'DD-MM-YYYY') AND TO_DATE(substr('13-07-2018 00:00', 1, 10),'DD-MM-YYYY'))
AND Y.IS_DELETE=0
GROUP BY Y.YARD_NAME;
。有人知道原因吗?
avaticaSqlexception
答案 0 :(得分:0)
您传递的值都是硬编码字符串,因此将parameterType
更改为String
或仅删除parameterType
属性
<insert id="insert" parameterType="String">
insert into stats_sms (pin,prizeId,templateId,sendTime) values ('123','123','123','123')
</insert>
OR
<insert id="insert">
insert into stats_sms (pin,prizeId,templateId,sendTime) values ('123','123','123','123')
</insert>