|
Re: Question on teneo.mapping.join_table_for_non_contained_associations [Teneo] [message #1027871 is a reply to message #1027789] |
Wed, 27 March 2013 14:34 |
Martin Taal Messages: 5468 Registered: July 2009 |
Senior Member |
|
|
Hi Josh,
The reason that I set this as the default is that it is the safest from a model --> rdb mapping perspective. It gives
the least possibility of name clashes when creating the database schema. With complex models with multiple inheritance
and with for example the oracle 30-character-limit join column names can accidentally clash. If someone tries Teneo for
the first time I don't want them to get stuck/disappointed on such a 'silly' thing as clashes in names.
A join table is less performance effective, but sometimes it is needed if an element can be present in a list multiple
times (unique==false).
The hibernate docs has a separate topic on collection mapping:
http://docs.jboss.org/hibernate/orm/4.1/manual/en-US/html_single/#performance-collections
See also this wiki page:
http://wiki.eclipse.org/Teneo/Hibernate/ModelRelational/Association_Mapping
gr. Martin
On 03/27/2013 01:14 PM, Josh A wrote:
> Hi All,
>
> As far as i understand, for a one to many non contained association, Teneo creates a Join table by default. I have
> verified that i can stop the join table creation by setting the property
> teneo.mapping.join_table_for_non_contained_associations to false.
>
> But, before i opt for this, I am trying to understand whether i am missing something? Is there a reason why Teneo chose
> to represent one to many non-contained association via a Join table(rather than by just 2 primary tables)?
> Thanks,
> Josh
--
With Regards, Martin Taal
Springsite/Elver.org
Office: Hardwareweg 4, 3821 BV Amersfoort
Postal: Nassaulaan 7, 3941 EC Doorn
The Netherlands
Cell: +31 (0)6 288 48 943
Tel: +31 (0)84 420 2397
Fax: +31 (0)84 225 9307
Mail: mtaal@xxxxxxxx - mtaal@xxxxxxxx
Web: www.springsite.com - www.elver.org
|
|
|
|
Powered by
FUDForum. Page generated in 0.02881 seconds