配置如下:

  1. <select id="getBlackListListTypes" resultClass="java.lang.Integer" parameterClass="java.lang.Integer"> 
  2.         SELECT distinct(list_type)  FROM black_list 
  3.         <dynamic prepend="where"> 
  4.             <isNotEmpty prepend="and" property="appId"> 
  5.                 app_Id = #appId# 
  6.             </isNotEmpty> 
  7.         </dynamic> 
  8.     </select> 

报错:

Caused by: com.ibatis.common.beans.ProbeException: There is no READABLE property named 'appId' in class 'java.lang.Integer'

 

 

解决方案:app_Id = #value#

原因参考:http://bakcom.iteye.com/blog/226036