mybatis报错信息记录:

### Error querying database.  Cause: org.apache.ibatis.reflection.ReflectionException: There is no getter for property named 'batchDetails' in 'class com.mybatis.model.Batch'

### Error querying database.  Cause: org.apache.ibatis.reflection.ReflectionException: There is no getter for property named 'batchDetails' in 'class com.mybatis.model.Batch'

这个问题会气死人,单词写错了

      <collection property="batchList" ofType="com.mybatis.model.Batch"><id column="batch_id" property="batch_id"/><result column="cus_id" property="cus_id"/><result column="number" property="number"/><result column="createtime" property="createtime" javaType="java.util.Date"/><result column="note" property="note"/><!--订单(批次)明细--><collection property="batchDetails" ofType="com.mybatis.model.BatchDetail"><id column="id" property="id"/><result column="batch_id" property="batch_id"/><result property="product_id" column="product_id"/><result property="product_num" column="product_num"/><!--每个明细对应单独(一对一)的说明--><association property="finacialProduct" javaType="com.mybatis.model.FinacialProduct"><id column="product_id" property="id"/><result column="name" property="name"/><result column="price" property="price"/><result column="detail" property="detail"/></association></collection></collection>

其中第八行的<collection property="batchDetails",要对应第一行的ofType="com.mybatis.model.Batch">

Bath.java中的字段

public class Batch {private int batch_id;private int cus_id;private String number;private Date createtime;private String note;private List<BatchDetail> batchDetials;
}

这边写的是batchDetials

batchDetials和batchDetails

此类报错和描述的一样,就是找不到,可以全局搜索找一下报错的字段等方法来测试

mybatis 报错There is no getter for property named 'XXX' in 'class com.xx.xx'相关推荐

  1. 使用mybatis-plus时mybatis报错There is no getter for property named ‘xxx‘ in ‘class com.xxx.xxx.xxxMybatis

    今天给项目的数据字典查询添加通用方法,发现里边已经有了一个查询所有数据字典的方法 List<Dict> selectDictList(); 但我想设置的方法是根据数据字典的code查询出所 ...

  2. mybatis报错There is no getter for property named '***' in 'class ***'

    mybatis报错There is no getter for property named '***' in 'class ***', 检查一看是xml中映射字段拼写错误,大小写. 有的时候用插件生 ...

  3. Mybatis报错There is no getter for property named 'id' in 'class java.lang.String'

    昨天运行公司项目的一个模块时,后台报了一个错: Caused by: org.apache.ibatis.reflection.ReflectionException: There is no get ...

  4. Mybatis报错There is no getter for property named ‘userID‘ in ‘class com.imooc.bilibili.domain.UserInfo

    这是有错误的: 问题在于 类 com.imooc.bilibili.domain.UserInfo 中根本就没有userID这个属性,只有userId属性,所以会报no getter for prop ...

  5. mybatis报错There is no getter for property named '***' in 'class ***'问题

    最近自己在学ssm,所以就想把自己遇到的所有bug都记录下来,不喜忽喷,如果对你有帮助的,帮忙点个赞,码字不易. 错误提示: 根据错误提示,说是没有获取到userCust这个属性,看了下xml映射文件 ...

  6. 解决MyBatis的报错 There is no getter for property named ‘*‘ in ‘class java.lang.String‘

    报错样式: Mapper的内容: 核心问题就是这一句: There is no getter for property named '*' in 'class java.lang.String' 意思 ...

  7. mybatis-plus报错There is no getter for property named ‘null‘ in ‘xx‘和Could not set property ‘XXX‘ of ‘

    坑一:mybatis-plus生成的代码如果报错:There is no getter for property named 'null' in 'xx' 一般是在调用封装的diupdateById方 ...

  8. MyBatis遇到:There is no getter for property named ‘Xxx‘ in ‘class xxx.xxx.Xxx‘问题

    问题 org.apache.ibatis.exceptions.PersistenceException: ### Error querying database. Cause: org.apache ...

  9. There is no getter for property named ‘xxx‘ in ‘class com.test.project.entity.

    SpringBoot 项目使用mybatis操作数据库时报错 There is no getter for property named 'xxx' in 'class com.test.projec ...

最新文章

  1. C examples
  2. ES _source字段介绍——json文档,去掉的话无法更新部分文档,最重要的是无法reindex...
  3. MySql8.0.16安装
  4. linux下mysql tmp满_MySQL服务器/tmp目录被占满
  5. python database is locked_sqlite遇到database is locked问题的完美解决
  6. android 价格排序筛选页面,Android应用开发之基于Popupwindow实现的筛选房源信息等相关的可自由排序控件...
  7. java移动接口发短信_Java面试零碎知识点
  8. 亚马逊创始人贝佐斯离婚协议本周生效 前妻分得380亿美金
  9. Linux驱动编写(块设备驱动代码)
  10. vue组件制作专题 - (mpvue专用)在mpvue中纯自己写css实现简单左右轮播
  11. php+ci对mysql进行增删改查
  12. mysql 逻辑类型_MySQL逻辑架构(一)
  13. java扩展类库_Java 类库和常用类库
  14. 腾讯云学生服务器分享
  15. 南京银行网站连接不到服务器,南京银行网络准入控制平台
  16. [安装之1] dell设置从ssd启动_如何进bios设置ssd固态硬盘为第一启动
  17. ExoPlayer修改播放器UI
  18. 文本与字体样式3.0
  19. QQ安装教程 2 -for wuqs
  20. Android学习系列(22)--App主界面比较

热门文章

  1. cpu风扇调速_乔思伯推出两款新风冷散热器:平价双热管和四热管风冷,带9cmRGB风扇...
  2. php cms 源码小说,PHPMAOS 强大的小说CMS系统
  3. mt6739怎么root,mt6739怎么改串号
  4. 10.数据结构:栈和队列
  5. 应用负载均衡之LVS(一):基本概念和三种模式
  6. 一夜暴涨超200%,短期高光的开心汽车为何难笑到最后?
  7. Unity3D Shader系列之渲染流水线
  8. 如何在计算机写作业英语作文,关于抄作业的英语作文4篇
  9. 微信小说分销系统设计之使用百度Echarts地图统计功能统计微信粉丝地域分布情况...
  10. 二分查找,超详细解读与代码实现,看完不会取关