在使用mybatis进行多参数传递时,报错:

A query was run and no Result Maps were found for the Mapped Statement 'xx.xx.'.  It's likely that neither a Result Type nor a Result Map was specified.

后来发现,原来是没有指定resultMap或resultType

mybatis中的所有查询,都必须返回resultType或者resultMap的值,否则就会报如上错误的。

到此,问题就解决了。

可是我又好奇了,resultMap怎么使用呢?

这就涉及到多表联查

请看下文!

....................

----------------------------------------------------------------------------
大家好,我是ABKing

金麟岂是池中物,一遇风云便化龙!
欢迎与我交流技术问题

mybatis使用map传递多参数报错:A query was run and no Result Maps were found for the Mapped Statement的更多相关文章

  1. mybatis报错:A query was run and no Result Maps were found for the Mapped Statement、、Property [login_ip] not found on type [com.thinkgem.jeesite.common.permission.entity.PremissUser]问题解决

    今天在做ssm项目的时候出现了: 先是出现 了错误: mybatis报错:A query was run and no Result Maps were found for the Mapped St ...

  2. mybatis报错:A query was run and no Result Maps were found for the Mapped Statement

    转自:https://blog.csdn.net/u013399093/article/details/53087469 今天编辑mybatis的xml文件,出现如下错误: 程序出现异常[A quer ...

  3. A query was run and no Result Maps were found for the Mapped Statement 'user.insertUser!selectKey'. It's likely that neither a Result Type nor a Result Map was specified.

    使用mybatis时出现异常问题: 有如下的错误 Error querying database. Cause: org.apache.ibatis.executor.ExecutorExceptio ...

  4. ExecutorException: A query was run and no Result Maps were found for the Mapped Statement ‘com.win.mall.dao.CartMapper.test’. It’s likely that neither a Result Type nor a Result Map was specified.

    ExecutorException: A query was run and no Result Maps were found for the Mapped Statement 'com.win.m ...

  5. mybatis配置文件xxxx.xml中缺失返回类型的后果A query was run and no Result Maps were found

    使用mybatis时出现异常问题: 有如下的错误 Error querying database.  Cause: org.apache.ibatis.executor.ExecutorExcepti ...

  6. A query was run and no Result Maps were found for...原来是mapper.xml文件出了问题,是使用MyBatis最常见的一种错误

    今天遇到一个问题,原来是mapper.xml文件出了问题,是使用MyBatis最常见的一种错误 报错的结果是这样的: A query was run and no Result Maps were f ...

  7. 单元测试时候使用[ClassInitialize]会该方法必须是静态的公共方法,不返回值并且应采用一个TestContext类型的参数报错的解决办法

    using Microsoft.VisualStudio.TestTools.UnitTesting; 如果该DLL应用的是 C:\Program Files\Microsoft Visual Stu ...

  8. 【spring mvc】后台spring mvc接收List参数报错如下:org.springframework.beans.BeanInstantiationException: Failed to instantiate [java.util.List]: Specified class is an interface

    后台spring mvc接收List参数报错如下:org.springframework.beans.BeanInstantiationException: Failed to instantiate ...

  9. mybatis 中文做参数报错

    一个简单的查询,如果参数中有中文.如下: <select id="xxxx" resultType="hashmap"> select * from ...

随机推荐

  1. WPF 多个选项卡TabControl 页面分离

    此项目源码下载地址:https://github.com/lizhiqiang0204/TabControl-page-separation 每个页面的按键处理事件直接对应该页面下的cs文件 Main ...

  2. Markdown小结

    Markdown标题 以# (#号加空格)开头的行会被视为标题,根据#的数量分为一到六级标题 # 一级标题 ## 二级标题 … ###### 六级标题 Markdown 水平线 一行由三个以上连续的减 ...

  3. .NET DotnetSpider--WebDrvierSpider(ajax动态加载的数据获取)

    爬虫获取数据时,可能会遇到AJAX加载的页面,如果无法分析出接口的话,就只能使用秘密武器——WebDriverDownloader.不过最好还是分析出接口为好,WebDriver的性能实在是太低了.现 ...

  4. forEach、map、filter、reduce的区别

    1.相同点: 都会循环遍历数组中的每一项: map().forEach()和filter()方法里每次执行匿名函数都支持3个参数,参数分别是:当前元素.当前元素的索引.当前元素所属的数组: 匿名函数中 ...

  5. vue发布到iis

    1.npm  run build. 执行打包命令,会在目录生成dist目录,这个目录里放的就是打包好的文件. 2.把dist目录下的文件发布到iis即可. 测试发现:发布到iis的虚拟目录不行.必须是 ...

  6. Spring Cloud Stream教程(四)消费群体

    虽然发布订阅模型可以轻松地通过共享主题连接应用程序,但通过创建给定应用程序的多个实例来扩展的能力同样重要.当这样做时,应用程序的不同实例被放置在竞争的消费者关系中,其中只有一个实例预期处理给定消息. ...

  7. pyCharm报错"your evaluation license has expired, pycharm will now exit"解决方法(实测)

    一.修改C:\Windows\System32\drivers\etc 目录下的hosts文件 1.打开hosts文件,路径是 c:\windows\system32\drivers\etc\host ...

  8. 关于TCP/IP,必须知道的十个知识点(转)

    三次握手四次挥手可参考:http三次握手,四次挥手 本文整理了一些TCP/IP协议簇中需要必知必会的十大问题,既是面试高频问题,又是程序员必备基础素养. 一.TCP/IP模型 TCP/IP协议模型(T ...

  9. JPA使用中遇到Caused by: org.hibernate.hql.internal.ast.QuerySyntaxException: XXX is not mapped

    在写自定义查询时,Query注解中写的JPQL,表名和列名都应该是映射的Java类和属性,不能写表名或者字段名

  10. Spring Security 报There is no PasswordEncoder mapped for the id "null"

    查了下发现是spring security 版本在5.0后就要加个PasswordEncoder了 解决办法 在securityConfig类下加入NoOpPasswordEncoder,不过官方已经 ...