mybatis map文件中 resultMap中column和sql查询结果对应, property和实体private对应

 <resultMap id="VideoYcAppResultMap" type="com.video.core.pojo.VideoYcApp" >

    <id column="CarId" property="carId" jdbcType="BIGINT" />
<id column="VideoId" property="videoId" jdbcType="BIGINT" /> </resultMap>
 <sql id="Base_Column_List_Video_App">
c.CarId,v.VideoId,v.Title,v.TotalVisit,v.TotalComment,v.CreatedDate,v.ImageLink,vr.MobileFileLink,Type=2
</sql>
public class VideoYcApp implements Serializable {
private Long carId;
private Long videoId;
private String title; public Long getCarId() {
return carId;
} public void setCarId(Long carId) {
this.carId = carId;
} public Long getVideoId() {
return videoId;
} public void setVideoId(Long videoId) {
this.videoId = videoId;
} public String getTitle() {
return title;
} public void setTitle(String title) {
this.title = title;
} }

mybatis column 和property的更多相关文章

  1. spring boot 2.0.0 + mybatis 报:Property 'sqlSessionFactory' or 'sqlSessionTemplate' are required

    spring boot 2.0.0 + mybatis 报:Property 'sqlSessionFactory' or 'sqlSessionTemplate' are required 无法启动 ...

  2. java mybatis Column 'AAA' in where clause is ambiguous

    今天在java mybatis项目中遇到一个问题,“java mybatis Column 'AAA' in where clause is ambiguous”, 这是由于在多表连接查询的时候,遇上 ...

  3. Mybatis的ResultMap对column和property

    首先,先看看这张图,看能不能一下看明白:   select元素有很多属性(这里说用的比较多的): id:命名空间唯一标识,可以被用来引用这条语句 parameterType:将会传入这条语句的参数类的 ...

  4. Springboot 2.0.4 整合Mybatis出现异常Property 'sqlSessionFactory' or 'sqlSessionTemplate' are required

    在使用Springboot 2.0.4 整合Mybatis的时候出现异常Property 'sqlSessionFactory' or 'sqlSessionTemplate' are require ...

  5. springBoot中mybatis错误之 Property 'configuration' and 'configLocation' can not specified with together 解决

    mybatis.config-location与mybatis.config-locations不同 mybatis.config-location不加载全局配置文件

  6. 解决mybatis中 数据库column 和 类的属性名property 不一致的两种方式

    解决方式way1:resultMap (1)studentMapper.xml <!-- 当数据库的字段名 和 类的属性名 不一致的时候的解决方式:2种 way1--> <selec ...

  7. Cause: org.apache.ibatis.reflection.ReflectionException: Could not set property 'orderdetails' of 'class com.luchao.mybatis.first.po.Orders' with value 'Orderdetail [id=null, ordersId=3, itemsId=1, it

    从上面异常的解释来看是因为反射不能将Orders设置到orderdetails属性上,仔细检查了MyBatis的配置文件,发现: <collection property="order ...

  8. 关于myBatis的问题There is no getter for property named 'USER_NAME' in 'class com.bky.model.实例类'

    现在流行的 ssm(spring + struts2 + myBatis)  持久层的mybatis是需要配置映射器的,找了个demo连接的数据库是MySQL 于是就修改了一下弄成了连接Oracle的 ...

  9. mybatis父查询值嵌套传递/column传入多个参数值

    mybatis中collection的column传入多个参数值(使用父查询的映射值) property description column 数据库的列名或者列标签别名.与传递给resultSet. ...

随机推荐

  1. Asp.net博客系统收集和简单介绍

    国内Asp.net博客系统收集和简单介绍       [转载文章,仅供个人参考,引自http://www.soyaoo.com/Blog/post/92.html] 1.ZJ-Blog程序简介:基于A ...

  2. 【WPF】Silverlight中的Action与Trigger

    最近做的Silverlight项目上用到了大量的拖拽,自动跟随等功能,由于赶时间,加上对Silverlight半生不熟,用的是最简单也是最不好维护的方法.项目忙完了闲下来,想重构一下代码,想起了Tri ...

  3. c++-pimer-plus-6th-chapter05

    Chapter Review 1 An entry-condition loop evaluates a test expression before entering the body of the ...

  4. LeetCode--443--压缩字符串(未看)

    问题描述: 给定一组字符,使用原地算法将其压缩. 压缩后的长度必须始终小于或等于原数组长度. 数组的每个元素应该是长度为1 的字符(不是 int 整数类型). 在完成原地修改输入数组后,返回数组的新长 ...

  5. gdb 不同位置,函数调用参数显示差异

    gdb 不同位置,函数调用参数显示差异,如: copy_strings (argc=1, argv=0xffcf08, page=0xffce6c, p=131068, from_kmem=2) at ...

  6. Android的组件化和模块化

    Android随着业务的增多,而且后续新的需求的增加,代码的修改会变得非常频繁 然后最近在看组件化和模块化 公司的业务没有那么大,所以这种方式我并没有采取 但是还是需要了解下他的使用机制 还有优缺点之 ...

  7. 「THUWC 2017」在美妙的数学王国中畅游

    这个题目很明显在暗示你要用泰勒展开. 直接套上去泰勒展开的式子,精度的话保留12项左右即可. 分别维护每一项的和,可能比较难写吧. 然后强行套一个LCT就没了.

  8. vim操作(待补充)

    :wq 存盘 + 退出 (:w 存盘, :q 退出) :e 打开新文件 :q 退出 h.j.k.l,分别控制光标左.下.上.右移一格. 按Ctrl+B:屏幕往后移动一页.[常用] 按Ctrl+F:屏幕 ...

  9. Spring boot(六)优雅使用mybatis

    orm框架的本质是简化编程中操作数据库的编码,发展到现在基本上就剩两家了,一个是宣称可以不用写一句SQL的hibernate,一个是可以灵活调试动态sql的mybatis,两者各有特点,在企业级系统开 ...

  10. rsync+inotify

    一.rsync 1.1rsync是啥 相当于cp.scp.rm等工具,但优于这些工具,主要用在数据备份 1.2.rsync安装 yum -y install rsync --update 客户端删除文 ...