MyBatis切换至MyBatis-plus踩坑Invalid bound statement (not found):
部分情况可以参考https://blog.csdn.net/wwrzyy/article/details/86034458
我的问题出现的根本原因就是没有扫描到mapper的xml文件
因为MyBatis与MyBatis-plus配置不同
我在切换后,没有写MyBatis-plus的配置,只是保留了MyBatis的配置
mybatis:
config-location: classpath:mybatis/mybatis-config.xml
mapper-locations: classpath:mybatis/mapper/*.xml
configuration:
map-underscore-to-camel-case: true
上面是MyBatis的配置,应删掉,并修改为,注意是mybatis-plus
mybatis-plus:
mapper-locations: classpath:mybatis/mapper/*.xml
configuration:
map-underscore-to-camel-case: true
本博客文章主要供博主学习交流用,所有描述、代码无法保证准确性,如有问题可以留言共同讨论。