找了一天的bug,以下时mybatis报错内容:
org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'xxxController': Unsatisfied dependency expressed through field 'xxxService';
通过检查以下问题没有错误:
- 检查xml的namespace是否和mapper文件的名称一一对应
- 检查方法名称是否对应
- 检查返回值类型
- 去除xml文件中的中文注释
发现问题所在
错误位置:
这里jdbcType必须大写
解决办法:改为大写