Caused by: org.apache.ibatis.reflection.ReflectionException: There is no getter for property named
时间: 2023-10-15 07:24:17 浏览: 137
Mybatis单个参数的if判断报异常There is no getter for property named 'xxx' in 'class java.lang.Integer'的解决方案
该错误是由于没有名为"xxxxx"的属性的getter方法引起的。
根据提供的代码,问题出在PersonMapper接口中的findPersonByMobile方法上。该方法没有使用@Param注解来指定参数的名称。 为了解决这个问题,你需要给findPersonByMobile方法的参数加上@Param("mobile")注解。 这样MyBatis就能正确地识别参数名称并进行映射了。<span class="em">1</span><span class="em">2</span><span class="em">3</span>
#### 引用[.reference_title]
- *1* [Caused by: org.apache.ibatis.reflection.ReflectionException: There is no getter for property named](https://blog.csdn.net/loney_wolf/article/details/107386943)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v93^chatsearchT3_2"}}] [.reference_item style="max-width: 50%"]
- *2* *3* [Caused by: org.apache.ibatis.reflection.ReflectionException: There is no getter for property named '](https://blog.csdn.net/FincherJF_Yuan/article/details/84617853)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v93^chatsearchT3_2"}}] [.reference_item style="max-width: 50%"]
[ .reference_list ]
阅读全文