我是靠谱客的博主 愤怒猎豹,这篇文章主要介绍SpringBoot中因xml文件位置导致报错Invalid bound statement (not found): com.atguigu.service_edu.mapper.EduCourse,现在分享给大家,希望可以做个参考。

此项目中我的Mapper的对应xml文件放在了src/main/java的mapper里,而不是src/resources里

解决办法:

pom中加


<build>
<resources>
<resource>
<directory>src/main/java</directory>
<includes>
<include>**/*.xml</include>
</includes>
<filtering>false</filtering>
</resource>
</resources>
</build>

application.properties中加入

#配置mapper xml文件的路径
mybatis-plus.mapper-locations=classpath:com/atguigu/service_edu/mapper/xml/*.xml

 

最后

以上就是愤怒猎豹最近收集整理的关于SpringBoot中因xml文件位置导致报错Invalid bound statement (not found): com.atguigu.service_edu.mapper.EduCourse的全部内容,更多相关SpringBoot中因xml文件位置导致报错Invalid内容请搜索靠谱客的其他文章。

本图文内容来源于网友提供,作为学习参考使用,或来自网络收集整理,版权属于原作者所有。
点赞(108)

评论列表共有 0 条评论

立即
投稿
返回
顶部