there have been many articles on the Internet explaining the possible reasons for this error, nothing more than the following:
1. Java method does not exist in mapper.xml, and then the method of executing Mapper will report the
. The return value of xxxmapper.java method is List, while the select element does not correctly configure ResultMap, or only configure ResultType
4. If you confirm that there is no problem above, please modify the corresponding XML file, such as deleting a blank line, save. 5. See if the XML configuration path of mapper is correct
error 2 treatment.
maven default would make all configuration files under the SRC/main/resources and SRC/main/Java under all the Java files packaged or published to the target \ classes here, but the reality we may under the SRC/main/Java also placed some configuration files such as hibernate configuration file or mybatis mapper configuration files, etc., if you don’t do some additional configuration, after that our packaging projects may find these must be a resource file, So add a configuration like the following to the POM.xml so that the XML file under SRC /main/ Java is copied to the corresponding class directory along with the Java compiled class file.
<build> <resources> <resource> <directory>src/main/java</directory> <includes> <include>**/*.properties</include> <include>**/*.xml</include> </includes> <filtering>false</filtering> </resource> </resources> </build>
- Invalid bound statement (not found) of custom SQL in mybatisplus
- [Solved] org.apache.ibatis.binding.BindingException: Invalid bound statement (not found): com.zyh.springboot.
- Spring boot can’t scan XML (invalid bound statement (not found))
- solve org.apache.ibatis . binding.BindingException : invalid bound statement (not found)
- org.apache.ibatis.binding.BindingException: Invalid bound statement (not found): com.xxx.dao.UserDao
- error: a label can only be part of a statement and a declaration is not a statement (How to Fix)
- How to Fix Pandoc wasn’t found.pdflatex not found on PATH
- How to Fix Warning: Statement lambda can be replaced with expression lambda
- How to Fix Error CGContextSetStrokeColorWithColor: invalid context 0x0
- How to Fix Failed to open \EFI\BOOT\grubx64.efi Not Found
- How to Fix Spring Boot OTS parsing error: Failed to convert WOFF 2.0
- How to Fix The error may exist in com/kuang/dao/UserMapper.xml
- Python: How to Fix “Ord() expected string of length 1, but int found”
- How to Fix Session is not Connecting (How to Diagnose it)
- How to Fix Error: JavaFX cannot find fxml
- Failed to configure a DataSource: ‘url’ attribute is not specified and no embedded (How to Fix)
- How to Fix nbconvert failed: Pandoc wasn’t found. Please check that pandoc is installed:
- How to Fix LDPlayer4 Proxy Setting Not Work Issue
- How to Fix Unknown error: Unable to build: the file dx.jar was not loaded from the SDK folder!
- VScode: How to Fix “Comments are not permitted in JSON” issue