【发布时间】:2011-05-17 18:52:42
【问题描述】:
我有一个具有 ObjectX 属性的实体类:
@OneToOne(fetch = FetchType.LAZY)
@PrimaryKeyJoinColumn
public ClassOfObjectX getObjectX() {
return this.ObjectX;
}
这个 ObjectX 不能为空?
在 Hibernate 3.4 中,我可以毫无问题地将这个对象保存在存储库中 但现在在 Hibernate 3.6 中它抛出了这个异常:
org.hibernate.PropertyValueException: not-null property references a null or transient value:
【问题讨论】:
标签: hibernate join null transient one-to-one