摘要:
hibernate默认的,以及网络上的主流支持left join的表关系是one-to-many的,可以使用left join fetch(需要配置lazy="true" fetch="select"),也可以使用Criteria或者CriteriaQuery(link1link2)来进行查询。对于many-to-one,首先我们先建两个model:@Entitypublic class ClassOne { public String id; public boolean isDeleted; }@Entitypublic class ClassTwo 阅读全文