nagkumar wrote:
Based on my current experience and reading the example of Bid and Item in Java Persistance with Hibernate book.. this does not seem to be possible.
Thank you for confirming my suspicion.
In the depicted constellation the to-one relationship Person->Address is essentially not an many-to-one but a "degenerated" one-to-many relationship. I hoped there would have been some (undocumented) mapping.
Kind regards,
Frank
Btw: OpenJPA seems to supports this constellation, also undocumented but pure JPA:
Code:
@Entity
public class Person {
@OneToOne
@JoinColumn(name="Address.Person_id", referencedColumnName="id")
private Address address;
...
}