本文共 493 字,大约阅读时间需要 1 分钟。
org.mybatis..MyBatisSystemException: nested exception is org.apache.ibatis.binding.BindingException
出现参数找不到的问题
要注意dao层方法中,出现多个参数(参数类型不一致),在MyBatis配置文件中就要对参数进行类型声明
void updateEquipment(@Param("equID") Integer equID ,@Param("equName") String equName);
<update id="updateEquipment">
update equipment set equName = #{equName,jdbcType=VARCHAR} where equID = #{equID,jdbcType=INTEGER}
</update>
注意:
当dao层方法中,只有一个参数,可以不使用@Param,当有多个参数时要使用
参考地址:http://blog.csdn.net/u014079773/article/details/51865492