1
我有以下情形:休眠@OneToMany內@Embeddable
@Entity
class A {
@ElementCollection
private Set<B> setOfB;
}
@Embeddable
class B{
@OneToMany
private Set<C> setOfC;
}
@Entity
class C{
private String name;
}
繼this question看起來這是可行的,但是我收到以下錯誤。任何想法我做錯了什麼?
org.hibernate.MappingException: Could not determine type for: java.util.Set, at table: A_setOfB, for columns: [org.hibernate.mapping.Column(setOfB.setOfC)]
謝謝。