So, I\'m not sure how to ask this question, as it seems like it should be pretty easy to find the answer to this one.
I have 3 tables; ContentHeader, ContentType1 a
You can create a composite id class that only has the ContentHeader:
@Embeddable
public class ContentKey implements java.io.Serializable {
@ManyToOne(cascade = {}, fetch = FetchType.LAZY)
@JoinColumn(name = "ID", updatable = true)
private ContentHeader header;
// ...
}
@Entity
@Inheritance(strategy=InheritanceType.TABLE_PER_CLASS)
public abstract class Content {
@Id
public ContentKey getContentKeyId()
// ...
}
That should do the trick.