提示错误如下==> Preparing: select count(0) from (select a.NAME, a.Y_ID, a.QR_ID, a.PHONE, a.SHEQU, a.ADDIN, a.USE_FLAG, a.IC_ID, a.BAG_NUM1, a.BAGN_UM2, a.BAGN_UM3, a.BAG_NUM_SET, a.EMAIL, a.JIFEN, a.HUANBAOFENG, a.TIME, a.TYPE, a.YEZHU_ID from TB_YEZHU a where 1=1 and SHEQU = ? order by TIME desc,JIFEN desc) tmp_count 2016-10-25 10:18:45 -29964 [http-8080-2] DEBUG - {conn-10001, pstmt-20001} enter cache 2016-10-25 10:18:45 -29965 [http-8080-2] ERROR - org.mybatis.spring.MyBatisSystemException: nested exception is org.apache.ibatis.type.TypeException: JDBC requires that the JdbcType must be specified for all nullable parameters.
2条回答 默认 最新
- Dengrz 2016-10-25 02:38关注
总是提示上面的错误,我贴出出现错误的sql语句:
<!-- 列表 -->
select
a.NAME,
a.Y_ID,
a.QR_ID,
a.PHONE,
a.SHEQU,
a.ADDIN,
a.USE_FLAG,
a.IC_ID,
a.BAG_NUM1,
a.BAGN_UM2,
a.BAGN_UM3,
a.BAG_NUM_SET,
a.EMAIL,
a.JIFEN,
a.HUANBAOFENG,
a.TIME,
a.TYPE,
a.YEZHU_IDfrom TB_YEZHU a where 1=1 <if test="pd.SHEQU != 'admin'"> and SHEQU = #{pd.SHEQU} </if> <if test="pd.SEARCHKEY != null and pd.SEARCHKEY != ''"><!-- 关键词检索 --> and ( a.EMAIL LIKE CONCAT(CONCAT('%', #{pd.SEARCHKEY}),'%') or a.Y_ID LIKE CONCAT(CONCAT('%', #{pd.SEARCHKEY}),'%') or a.PHONE LIKE CONCAT(CONCAT('%', #{pd.SEARCHKEY}),'%') or a.ADDIN LIKE CONCAT(CONCAT('%', #{pd.SEARCHKEY}),'%') or a.NAME LIKE CONCAT(CONCAT('%', #{pd.SEARCHKEY}),'%') ) </if> order by TIME desc,JIFEN desc
解决 无用评论 打赏 举报