ibatis iterate 动态where条件报错
各位大拿帮忙看看这样写where条件有问题吗?为什么总是报错,也不知道是什么原因。小弟托了一个礼拜了,多谢多谢。红色的字段有问题吗?还是传入List里面的map对象的问题?
Error:
========================
com.citibank.eclipselite.bank.memfis.common.util.MemfisException : com.ibatis.common.jdbc.exception.NestedSQLException: --- The error occurred while applying a parameter map. --- Check the getTotalNoOfFundManagers-InlineParameterMap. --- Check the parameter mapping for the 'fieldValueList[0].value' property. --- Cause: com.ibm.db2.jcc.b.SqlException: [ibm][db2][jcc][10281][10295] 尚不支持 JDBC 类型 0。
========================
何解啊? 重谢!!!!!!!!!!!!!!
fundmanager.xml
==============
<select id="getTotalNoOfFundManagers" parameterClass="BaseDom" resultClass="int">
SELECT count(1) AS CN
<dynamic>
<isEqual property="authStatus" compareValue="UN">
FROM table </isEqual>
<isNotEqual property="authStatus" compareValue="UN">
FROM table </isNotEqual>
</dynamic>
WHERE
<iterate property="fieldValueList" conjunction="and">
$fieldValueList[].key$ = #fieldValueList[].value#
</iterate>
<select >
BaseDom.java
======================
public List getFieldValueList(){
List list = new ArrayList();
Map<String, String> map = new HashMap<String, String>();
map.put("Cloumn", "'MM'");
list.add(map);
return list;
}
fundmanagerDAO.java
==================
public int getTotalNoOfFundManagers(BaseDom dom) throws SQLException {
int i = 0;
try {
sqlMap.startTransaction();
i = (int)MemfisGenUtility.checkInteger(sqlMap.queryForObject("getTotalNoOfFundManagers",dom));
} catch (SQLException e) {
e.printStackTrace();
throw e;
}finally{
close(sqlMap);
}
return i;
}