MyBatis Error building SqlSession.
The error may exist in SQL Mapper Configuration
Cause: org.apache.ibatis.builder.BuilderException: Error parsing SQL Mapper Configuration. Cause: java.lang.ClassNotFoundException
In the configuration file:
<mappers>
<mapper class="com/base/dao/UserMapper.xml"/>
</mappers>
written as:
<mappers>
<mapper resource="com/base/dao/UserMapper.xml"/>
</mappers>
If you still can’t find it, you can configure pom.xml
<build>
<resources>
<resource>
<directory>src/main/resources</directory>
<includes>
<include>**/*.properties</include>
<include>**/*.xml</include>
</includes>
</resource>
<resource>
<directory>src/main/java</directory>
<includes>
<include>**/*.properties</include>
<include>**/*.xml</include>
</includes>
</resource>
</resources>
</build>
Similar Posts:
- [Solved] Springboot Error: invalid bound statement (not found)
- [Solved] Mybatis Error: Invalid bound statement (not found)
- [Solved] Mybatis: the binding mapper cannot be found Error: Org.apache.ibatis.binding.bindingexception: invalid bound statement (not found)
- [Solved] Mybatis Error: Invalid bound statement (not found)
- [Solved] Could not find resource com/cth/dao/UserImpl.xml & Single mapping file not found
- [Solved] Mybatis-config Error: Cannot load connection class because of underlying exception: com.mysql.cj.exceptions.WrongArgumentException: failed to parse the connection string near ‘;useUnicode=true&
- [Solved] Springboot Project mybatis Error: Invalid bound statement (not found)
- [Solved] Failed to configure a DataSource: ‘url’ attribute is not specified and no embedded datasource could be configured.
- The project is normal in eclipse, and an error is reported in IDEA [How to Solve]
- Failed to bind properties under