mybaties报错:There is no getter for property named 'table' in 'class java.lang.String'
报错是由于xml里获取不到这个table参数
package com.xxx.mapper;
import java.util.List;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
@Mapper
public interface UserMapper { User getUserById(long id); // @Select("select * from user_auth_0 ") // 查询所有,改为xml
List<User> findAll(); /**
* 加@Param("table") 解决问题: org.apache.ibatis.reflection.ReflectionException:
* There is no getter for property named 'table' in 'class java.lang.String'
* @param table
* @return
*/
int createTableTest(@Param("table") String table);
}
mybaties报错:There is no getter for property named 'table' in 'class java.lang.String'的更多相关文章
- MyBatis if test 传入一个数字进行比较报错 There is no getter for property named 'userState' in 'class java.lang.Integer'
在写MyBatis映射文件中,我要传入一个 int 类型的参数,在映射文件中用 'test' 中进行比较,我花了很长时间百度,发现都是不靠谱的方法,有把数字在比较时转成字符串用 equals 比较的. ...
- mybaits错误解决:There is no getter for property named 'parentId ' in class 'java.lang.String'
在使用mybaitis传参数的时候,如果仅传入一个类型为String的参数,那么在 xml文件中应该使用_parameter来代替参数名. 比如mapper中如下方法,只有一个String值 publ ...
- SSM框架报错分析(一)——There is no getter for property named 'XXX' in 'class java.lang.String'
一.发现问题 <select id="queryStudentByNum" resultType="student" parameterType=&quo ...
- 【Mybatis】mybatis查询报错org.apache.ibatis.reflection.ReflectionException: There is no getter for property named 'areaName' in 'class java.lang.String'
mybatis查询报错: Caused by: org.apache.ibatis.reflection.ReflectionException: There is no getter for pro ...
- 已解决: mybatis报错 org.apache.ibatis.reflection.ReflectionException: There is no getter for property named 'xxx' in 'class java.lang.String'
最近在练习MyBatis时 进行姓名的模糊查询时候出现 org.apache.ibatis.exceptions.PersistenceException: ### Error querying da ...
- MyBatis3: There is no getter for property named 'code' in 'class java.lang.String'
mybatis3 : mysql文如下,传入参数为string类型时‘preCode’,运行报错为:There is no getter for property named 'preCode' i ...
- mybatis之org.apache.ibatis.reflection.ReflectionException: There is no getter for property named 'time' in 'class java.lang.String'
mybatis接口 List<String> getUsedCate(String time); 配置文件 <select id="getUsedCate" pa ...
- mybatis问题: There is no getter for property named 'equipmentId' in 'class java.lang.String'
本文来源于翁舒航的博客,点击即可跳转原文观看!!!(被转载或者拷贝走的内容可能缺失图片.视频等原文的内容) 若网站将链接屏蔽,可直接拷贝原文链接到地址栏跳转观看,原文链接:https://www.cn ...
- 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' 一.发现问题 <select ...
随机推荐
- 黄聪:wordpress调试过程只显示500错误,不显示错误内容
在functions.php文件添加如下代码: add_filter('wp_die_handler', 'get_my_custom_die_handler'); function get_my_c ...
- 为什么Redis 单线程却能支撑高并发?
作者:Draveness 原文:draveness.me/redis-io-multiplexing 推荐阅读 1. Java 性能优化:教你提高代码运行的效率 2. 基于token的多平台身份认证架 ...
- C# convert between Image and Base64string
static void ImageMSDemo(string picPath) { byte[] imageArray = System.IO.File.ReadAllBytes(picPath); ...
- Z从壹开始前后端分离【 .NET Core2.0/3.0 +Vue2.0 】框架之三 || Swagger的使用 3.1
本文梯子 本文3.0版本文章 常见问题 1.Bug调试 2.经常有小伙伴遇到这个错误 3.路由重载 一.为什么使用Swagger 二.配置Swagger服务 1.引用Nuget包 2.配置服务 3.启 ...
- Python3---常见函数---open()
前言 该文章描述了Python3函数open的作用,以及使用方法. 修改时间:20191220 天象独行 函数open(name,mode,buffering)作用是打开一个文件,并且创建一个file ...
- Maven设置本地仓和阿里云远程仓
在maven项目导入jar包坐标时需要连接maven官方仓库下载,但是下载速度感人,所以来修改一下设置. 设置成为本地仓和连接阿里云的远程仓库. (本地仓如果没有这个jar) 找出相应配置文件:例如我 ...
- IDEA构建spring项目
这两天使用IDEA从零构建一个spring项目,之所以说从零,是因为,我这个小白呢,之前IDEA没有碰过,spring也只是知道个名字. 因为没有文档,遇到了好些坑,把这些记录一下吧. 构建的第一步, ...
- kali linux maltego-情报收集工具
Maltego是一个交互式数据挖掘工具,它为链接分析呈现有向图.该工具用于在线调查,以发现互联网上各种来源的信息片段之间的关系. 注册Maltego账号,注册地址:https://www.paterv ...
- iOS开发证书那点事儿
iOS开发是用Xcode作为开发工具,Xcode在安装之后就自带了模拟器(Simulator).模拟器是个好工具,它对用户没有任何要求,但是我们必须牢记一件事:开发出来的App最终是要在真机上执行,没 ...
- 1_Swift概况
Swift 标准库 解决复杂的问题并编写高性能,可读的代码 概况 Swift标准库定义了用于编写Swift程序的基本功能,其中包括 1.如基本数据类型Int,Double以及String 2.共同的数 ...