版权声明:本文是博主的知识结晶,未经博主允许不能转载用于商用 https://blog.csdn.net/zbr0819/article/details/88844215
idea导入gradle项目启动报错解决方法
启动编译时报错
Caused by: org.apache.ibatis.binding.BindingException: Invalid bound statement (not found): xxx.mapper.xxxMapper.xxx方法
错误原因
idea编译时classes文件夹中只有xxxMapper.class而resources文件夹中没有对应的xxxMapper.xml文件;
修改build.gradle文件
添加:
sourceSets.main.resources.srcDirs=["src/main/java","src/main/resources"]
更新后启动:
会在resources文件夹中放置对应的xxxMapper.xml文件