Skip to content

Instantly share code, notes, and snippets.

@kymtwyf
Last active October 17, 2015 01:06
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kymtwyf/08ac5d759bac1f9bf917 to your computer and use it in GitHub Desktop.
Save kymtwyf/08ac5d759bac1f9bf917 to your computer and use it in GitHub Desktop.
java 文件夹下 Mybatis 的xml被IDE忽略 (可能会导致HTTP Status 500 - Request processing failed; nested exception is org.apache.ibatis.binding.BindingException: Invalid bound statement (not found): xxx)

首先要确定xml的路径是否正确配置

一种方法是

直接把mybatis的xml放到src/main/resources

另外一种方法

pom.xml中加:

<resource>
    <directory>${basedir}/src/main/java</directory>
    <excludes>
        <exclude>**/*.java</exclude>
    </excludes>
</resource>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment