一身转战三千里,一剑曾百万师。这篇文章主要讲述A query was run and no Result Maps were found for the Mapped Statement相关的知识,希望能为你提供帮助。
Cause: org.apache.ibatis.executor.ExecutorException: A query was run and no Result Maps were found for the Mapped Statement ‘com.shadow.foretaste.UserInfoDao.getPhoneNum‘.
It‘s likely that neither a Result Type nor a Result Map was specified.
导致这个错误的原因是:
mapper.xml中没有指定返回值类型
< select id="getPhoneNum" > select phone_num from user_info where id = #{id} < /select>
修改后:
< select id="getPhoneNum" resultType="String"> select phone_num from user_info where id = #{id} < /select>
【A query was run and no Result Maps were found for the Mapped Statement】本文出自 “数据挖掘工程师的成长历程” 博客,请务必保留此出处http://qianqiansun.blog.51cto.com/13271301/1965502
推荐阅读
- 最新版勤哲Excel服务器V2016.12.0.292无限用户支持手机APP,微信,网页等功能不绑定电脑,任意安装,支持后续升级
- 学习angular之(ng-app)
- 迅为嵌入式4418开发板Android4.4-更改uboot开机LOGO
- android, 模拟器
- Android在 普通类(非Activity,多数为Adapter) 中 传输数据为空值解决方法 (在startActivity 用 intent传输数据)
- 本文教你如何调节电脑屏幕亮度
- 本文教你电脑无线网络连接不上
- 本文教你电脑u盘重装win10系统
- 电脑软件小白一键重装推荐安装办法图解