I'm encountering a weird problem in the following situation:
Assume i have three entities A, B, C
A has a simple PK, consisting of a single string
B has a composite PK, consisting of the same string as A, plus an integer field
C has a composite PK consisting of all the properties from B, plus two additional strings
Now, in B and C I want to map A using a @OneToMany annotation. To achieve this I assume that @MapsId is the right choice.
However, an exception is encountered:
MappingException: Unable to find column with logical name: <col_name> in org.hibernate.mapping.Table(<table name of B!>)
Testcase to follow...
Windows, Java 7