Spring Boot Mybatis Result Maps collection already contains value for *.BaseResultMap

当你复制一个*Mapper.xml文件到项目工程中,运行报错Mybatis Result Maps collection already contains value for *.BaseResultMap时,教你两步解决。

1.删除对应的这个*Mapper.xml文件,启动下项目,让其报下错。

2.然后再复制文件上去,再次启动就OK了。

时间: 2024-11-05 11:50:23

Spring Boot Mybatis Result Maps collection already contains value for *.BaseResultMap的相关文章

mybatisGenerator 代码自动生成报错 Result Maps collection already contains value for BaseResultMap

由于mybatis简单易学,比起Hibername来,更容易上手,代码也能自动生成.这几天研究了下代码自动生成的,参考: http://0609xiaohua.iteye.com/blog/1453570 但是把代码复制进来,运行了下,却跑不起来,报以下错误: Exception in thread "main" java.lang.ExceptionInInitializerError at com.test.Test.main(Test.java:12)Caused by: org

mybatis中Invalid bound statement (not found) 和 Result Maps collection already contains value for...错误解决方案

一.Invalid bound statement (not found) 使用mybatis有时候会报Invalid bound statement (not found)这种错误,总结了下,可能有两种情况如下: 1.mybatis的对应的mapper.xml找不到对应的命名sql或者名称与mapper接口名称不一致. 2.xml文件与接口名称都对,但是在mybatis配置文件中漏掉了配置,也会报这种错误. 二.Result Maps collection already contains v

mybatis(错误一) 项目启动时报“Result Maps collection already contains value forxxx”的解决方案

Result Maps collection already contains value for xyx.dsw.dao.mapper.admin.quotationwish.TempTestTableMapper.TempTestTableResult 一  错误信息: [html] view plain copy 19:26:05,446 ERROR [org.mybatis.spring.mapper.MapperFactoryBean] (org.mybatis.spring.mapp

MyBatis错误:Result Maps collection already contains value for novel.storage.mapper.NovelMapper.BaseResultMap

今天在写项目的时候遇到一个问题如下: org.apache.ibatis.exceptions.PersistenceException: ### Error building SqlSession.### The error may exist in NovelMapper.xml### The error occurred while processing mapper_resultMap[BaseResultMap]### Cause: org.apache.ibatis.builder.

mybatis 异常Result Maps collection does not contain value for java.lang.String

Result Maps collection does not contain value for java.lang.String 以上是我报的错. 只要报Result Maps collection does not contain value for*****的错误都是同一种错误. 问题排查: 从异常信息里无法看出具体是哪里出了错误.只提示调用出现错误的地方.但是经过检查后明显错误不是再此处的代码. 经过每个问题文件进行移除,一次次运行进行排查问题最终找到了错误的地方,处于一个xml里面的

MyBatis出错Result Maps collection does not contain value for java.lang.Integer

Servlet.service() for servlet [SpringMVC] in context with path [/eyou] threw exception [Request processing failed; nested exception is org.apache.ibatis.builder.IncompleteElementException: Could not find result map java.lang.Integer] with root causej

Result Maps collection already contains value for org.gwj.ssm.dao.CompanyMapper.BaseResultMap

八月 01, 2017 2:48:13 下午 org.apache.tomcat.util.digester.SetPropertiesRule begin 警告: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'source' to 'org.eclipse.jst.jee.server:ssm' did not find a matching property. 八月 01, 2017 2:4

解决Caused by: java.lang.IllegalArgumentException: Result Maps collection does not contain value for com.geek.dao.ContentDao.Integer

mybatis报错:Caused by: java.lang.IllegalArgumentException: Result Maps collection does not contain value for com.geek.dao.ContentDao.Integer 出错原因:一个手误 <select id="selectAllFirstNavigationName" resultMap="firstNavigation"> SELECT fi

spring boot+mybatis整合

LZ今天自己搭建了下Spring boot+Mybatis,比原来的Spring+SpringMVC+Mybatis简单好多.其实只用Spring boot也可以开发,但是对于多表多条件分页查询,Spring boot就有点力不从心了,所以LZ把Mybatis整合进去,不得不说,现在的框架搭建真的是方便.话不多说,进入正题. 一.java web开发环境搭建 网上有很多教程,参考教程:http://www.cnblogs.com/Leo_wl/p/4752875.html 二.Spring bo