Hi,
I'm starting with Hibernate and I manage to solve all my problems with <many-to-one> associations but <one-to-one> seems very confusing for me.
I need help to use Hibernate with <one-to-one> associations. I read in the Hibernate reference that the tables should share the same primary-key values, but they are required to have the same name(and the name must be the same in the database, in my classes or in both)?
Can I have the primary and the foreign key in separated fields or they should be the same field?
I read all kinds of helps, faqs and manuals all over the internet but I couldn't be able to solve my doubts.
If someane have any example with mappings, classes and schemas of database I would aprecciate it.
Thanks in advance,
F
|