[Prev] Thread [Next] |
[Prev] Date [Next]
Detecting inconsistencies of mapped-by declarations?
Joerg von Frantzius
Thu May 07 10:01:44 2009
in the XML metadata, it is possible to have multiple FCO fields, e.g.
B.a1 and B.a2, with identical mapped-by pointing to the same field of
the same related class, e.g. A.b. In effect this would theoretically
mean that the FK should be shared among different associations in the
object model. I don't think that this does make much sense.
Also it is possible to declare two fields in two different classes, e.g.
B1.a and B2.a, with the identical mapped-by pointing to the same field
of the same related class, e.g. A.a. That would mean that in theory two
FKs would have to be created for the same column, pointing to different
tables. That neither seems to make sense to me.
Should the implementation throw an error in such situations, warning the
user of the erroneous metadata?
artnology GmbH - Milastraße 4 - 10437 Berlin - Germany
Geschäftsführer: Ekkehard Blome (CEO), Felix Kuschnick (CCO)
Registergericht: Amtsgericht Berlin Charlottenburg HRB 76376
UST-Id. DE 217652550
RE: Detecting inconsistencies of mapped-by declarations? Erik Bengtson