MyBatis Exception: Could not find result map java.util.Map problem analysis and solution

Source: Internet
Author: User

MyBatis Exception: Could not find result map java.util.Map problem analysis and solution

Wrong wording
<select id= "Queryxxxcount" resultmap= "Java.util.Map" >

MyBatis reported Exception Log:
Org.apache.ibatis.builder.IncompleteElementException:Could not find result map java.util.Map
At Org.apache.ibatis.builder.MapperBuilderAssistant.setStatementResultMap (mapperbuilderassistant.java:354) ~[ mybatis-3.1.1.jar:3.1.1]
At Org.apache.ibatis.builder.MapperBuilderAssistant.addMappedStatement (mapperbuilderassistant.java:292) ~[ mybatis-3.1.1.jar:3.1.1]
At Org.apache.ibatis.builder.xml.XMLStatementBuilder.parseStatementNode (xmlstatementbuilder.java:113) ~[ mybatis-3.1.1.jar:3.1.1]
At Org.apache.ibatis.session.Configuration.buildAllStatements (configuration.java:579) ~[mybatis-3.1.1.jar:3.1.1]
At Org.apache.ibatis.session.Configuration.getMappedStatement (configuration.java:505) ~[mybatis-3.1.1.jar:3.1.1]
At Org.apache.ibatis.session.Configuration.getMappedStatement (configuration.java:500) ~[mybatis-3.1.1.jar:3.1.1]
At Org.apache.ibatis.binding.MapperMethod.setupCommandType (mappermethod.java:240) ~[mybatis-3.1.1.jar:3.1.1]
At Org.apache.ibatis.binding.mappermethod.<init> (mappermethod.java:71) ~[mybatis-3.1.1.jar:3.1.1]
At Org.apache.ibatis.binding.MapperProxy.invoke (mapperproxy.java:39) ~[mybatis-3.1.1.jar:3.1.1]
。。。


Correct wording:
<select id= "Queryxxxcount" resulttype= "Java.util.Map" >


Attention:
MyBatis reported abnormal log stack information positioning is not so accurate (where the error occurred can not directly based on the exception stack information directly to the problem method)
This time based on the exception stack information found is the normal method, but triggered the problem of the MyBatis

In the problem debugging, the lookup process: According to the SVN submission information, the newly submitted code is checked, commented out, and the actual debugging to accurately locate such problems.

MyBatis Exception: Could not find result map java.util.Map problem analysis and solution

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.