首页 > 代码库 > mybatis 异常 There is no getter for property named 'bizId' in 'class java.lang.Long'

mybatis 异常 There is no getter for property named 'bizId' in 'class java.lang.Long'

mybatis 异常 There is no getter for property named ‘bizId‘ in ‘class java.lang.Long‘

当使用mybatis进行传参的时候,参数只有一个时会出现这种类似的错误。

解决:

1.接口定义出,指定参数名

技术分享

 

2.在xml 中指定类型

技术分享

 

mybatis 异常 There is no getter for property named 'bizId' in 'class java.lang.Long'