Re: [Newbie]ManyToMany
Re: [Newbie]ManyToMany
- Subject: Re: [Newbie]ManyToMany
- From: David LeBer <email@hidden>
- Date: Wed, 17 Mar 2004 18:44:02 -0500
On 17-Mar-04, at 5:48 PM, Jonathan Rochkind wrote:
At 5:26 PM -0500 3/17/04, Kieran Kelleher wrote:
Forget having EoModeler make a many-to-many.
Just make relationships such as:
T1 <=>>T2 and T2<<=>T3, (where > is a to-one and >> is a to-many)
then you can use T1.T2.T3(), T3.T2.T1() and also use flattened
T1.T3() or T3.T1()
How could you use those flattened relationships from T1 to T3? Are
you suggesting defining the flattened relationship in the EOModel as a
class property, and ALSO defining the direct relationship as a class
property? I think this is rather a bad idea myself, but if you've
done it succesfully I'm interested in hearing about it.
Otherwise.... how could you "also use flattened T1.T3() or T3.T1()"?
My experience is you either use flattened relationships, or you don't.
If you don't (perhaps because you need exposed attributes in the
intermediary table), then you've got to go through the intermediary
table to get from T1 to T3 or vice versa.
--Jonathan
I concur, having a both flattened and unflattend relationships as class
properties at the same time is a bad thing. I know, I speak from
experience :-) Especially if you have a cascade delete rules in place -
mucho badness occurs.
;david
--
David LeBer
Codebase Software Systems
site: http://www.codebase.ca
blog: http://david.codebase.ca
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.