db-jdo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Joerg von Frantzius <joerg.von.frantz...@artnology.com>
Subject Re: Detecting inconsistencies of mapped-by declarations?
Date Thu, 07 May 2009 17:02:58 GMT
Andy Jefferson wrote:
>> Should the implementation throw an error in such situations, warning the
>> user of the erroneous metadata?
> Shared FK relations are a perfectly valid thing to have IMHO
> http://www.datanucleus.org/products/accessplatform_1_1/jdo/orm/one_to_many_collection.html#shared_fk
> You could have the same as that example with 1-1 and a discriminator for 
> determining the relation.
Sorry I had put it too general: what I really had in mind is that an FK
(value) in the same table row would be shared by two different
associations in the object model.

Since that datanucleus extension is about an additional
relation-discriminator to discern the two associations in a join table,
this is not the case in your example. I take it that this only works for
join tables, and not for single-FK mapping?
> The place of an ORM spec is to standardise particular relation types, not to 
> prevent other ones.

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

  • Unnamed multipart/mixed (inline, None, 0 bytes)
View raw message