用mybatis查询时,传入一个字符串传参数,且进行判断时,会报
There is no getter for property named 'xxxxx' in 'class java.lang.String
<choose>
<when test="xxx!= null and xxxx!=''">
WHERE VEHICLE_INCIDENTALS_ID = #{xxxx}
</when>
<otherwise>
WHERE VEHICLE_INCIDENTALS_ID = ''
</otherwise>
</choose>
<choose>
<when test="_parameter != null and _parameter !=''">
WHERE VEHICLE_INCIDENTALS_ID = #{_parameter}
</when>
<otherwise>
WHERE VEHICLE_INCIDENTALS_ID = ''
</otherwise>
</choose>
总之:不管你的参数是什么,都要改成"_parameter"