Details
Assignee
UnassignedUnassignedReporter
Michael MattMichael MattPriority
Major
Details
Details
Assignee
Unassigned
UnassignedReporter
Michael Matt
Michael MattPriority
Created February 14, 2006 at 1:21 PM
Updated January 6, 2025 at 2:29 PM
The request seems to be to add support for multi-column any keys. Right now, any associations are limited to a single join column and it’s not so easy to add support for multiple columns, because we’d need a mapping between foreign key join columns and primary/unique key target columns per discriminator. So we’d probably have to add
@JoinColumns
to@AnyDiscriminatorValue
. Apart from that, the whole boot and runtime model would need to be adapted to support multiple columns, since the fact that the key is singular is hard coded in many places.Original description
Any mapping with composite id-type throws MappingException 'property mapping has wrong number of columns'.
The zipped patch file contains:
-bugfix for AnyType.java
testcases any mapping with simple id-type and composite id-type