![](https://img-blog.csdnimg.cn/20201014180756754.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
Hibernate
icecoola_
这个作者很懒,什么都没留下…
展开
-
Hibernate注解@Transient
package org.springframework.data.annotation;import java.lang.annotation.ElementType;import java.lang.annotation.Retention;import java.lang.annotation.RetentionPolicy;import java.lang.annotation.T...原创 2018-03-01 18:34:08 · 366 阅读 · 0 评论 -
Hibernate注解@JsonIgnoreProperties@JsonIgnore
@JsonIgnoreProperties类注解,作用是json序列化时将java bean中的一些属性忽略掉,序列化和反序列化都受影响。转换实体时忽略json中不存在的字段解析json数据之忽略解析字段注解@JsonIgnoreProperties 接口的数据无法完全的预知,所以实体类字段有可能不完整@JsonIgnoreProperties转换实体时忽略json中不存...原创 2018-03-02 08:50:33 · 1551 阅读 · 0 评论 -
Hibernate JPA中@Transient、@JsonIgnoreProperties、@JsonIgnore、@JsonFormat、@JsonSerialize等注解解释
转自:https://www.cnblogs.com/softidea/p/5668697.html@jsonignore的作用作用是json序列化时将java bean中的一些属性忽略掉,序列化和反序列化都受影响。http://www.cnblogs.com/toSeeMyDream/p/4437858.html当表间有One2Many或Many2One时,会发生无限循环的场景,如何破?只要在S...转载 2018-03-16 09:52:58 · 1287 阅读 · 0 评论 -
Hibernate原生sql用例
public Map<String,String> getUserById(String userId) { Map<String, String> map = new HashMap<String, String>(); String sql="select a.userNo,(select h.code from t_cl...原创 2018-04-10 19:26:31 · 211 阅读 · 0 评论 -
JPA 各种基本用法
JPA 各种基本用法JPQL就是一种查询语言,具有与 SQL 相类似的特征, JPQL 是完全面向对象的,具备继承、多态和关联等特性,和hibernate HQL很相似。 查询语句的参数 JPQL 语句支持两种方式的参数定义方式: 命名参数和位置参数。 。在同一个查询语句中只允许使用一种参数定义方式。 命令参数的格式为:“ : + 参数名” 例:Query query = em.createQue...转载 2018-04-13 15:53:34 · 2425 阅读 · 0 评论