当传入数据只有一个时mybatis中<if>判断会出现There is no getter for property named 'subjectId' in 'class java.lang....
来源:互联网 发布:java包名命名规范 编辑:程序博客网 时间:2024/06/05 20:28
用”_parameter”代替当前参数
正确:
<select id="selectSubjectByPId" parameterType="java.lang.Integer" resultType="java.util.Map">select subjectId,subjectName from ts_subject where subjectParentId= 0 <if test="_parameter != null"> and subjectId = #{_parameter,jdbcType=INTEGER} </if></select>
错误:
<select id="selectSubjectByPId" parameterType="java.lang.Integer" resultType="java.util.Map">select subjectId,subjectName from ts_subject where subjectParentId= 0 <if test="subjectId != null"> and subjectId = #{subjectId,jdbcType=INTEGER} </if></select>
这时候就会出现异常.
There is no getter for property named 'subjectId' in 'class java.lang.Intege
0 0
- 当传入数据只有一个时mybatis中<if>判断会出现There is no getter for property named 'subjectId' in 'class java.lang....
- mybatis出现There is no getter for property named 'Id' in 'class java.lang.Intege
- 关于mybatis单独传入String时出现There is no getter for property named 'keyWord' in class 'java.lang.String'解决
- mybatis中出现There is no getter for property named 'depIds' in 'class java.lang.String'的错误
- Mybatis 对单独传入参数string进行判断时报There is no getter for property named '**' in 'class java.lang.String解决办法
- mybatis 基本类型的if条件判断问题 There is no getter for property named 'xxx' in 'class Java.lang.Integer'
- mybatis There is no getter for property named 'xx' in 'class java.lang.String
- Mybatis中传参包There is no getter for property named 'XXX' in 'class java.lang.String'
- Mybatis-There is no getter for property named 'XXX' in 'class java.lang.String'解决办法
- Mybatis中传参包There is no getter for property named 'XXX' in 'class java.lang.String'
- mybatis:There is no getter for property named 'xxx' in 'class java.lang.String'
- Mybatis-There is no getter for property named 'id' in 'class java.lang.String'
- mybatis There is no getter for property named 'xx' in 'class java.lang.String
- Mybatis中传参包There is no getter for property named 'XXX' in 'class java.lang.String'
- Mybatis中传参包There is no getter for property named 'XXX' in 'class java.lang.String'
- MyBatis There is no getter for property named 'xxx' in 'class java.lang.String'
- mybatis There is no getter for property named 'xx' in 'class java.lang.String
- mybatis 异常:There is no getter for property named 'classId' in 'class java.lang.Integer'
- 常用函数
- 使用phpexcel导出大容量数据时出现的相关问题
- Codeforces Round #409 (rated, Div. 2, based on VK Cup 2017 Round 2) C. Voltage Keepsake
- 奇舞学院学习笔记之JavaScript一页通
- Lua学习笔记(四)
- 当传入数据只有一个时mybatis中<if>判断会出现There is no getter for property named 'subjectId' in 'class java.lang....
- [BZOJ3179][Coci2012][线段树][贪心]RASPORED
- 8 指针与字符串
- Linux程序设计:读取键盘输入
- [BZOJ4373算术天才⑨与等差数列] 线段树
- 正方形面积
- 外边距margin-top right bottom left 设置方法 如果margin只设置两个值
- PHP实现简易计算器
- git详细 教程