Re: Reflexive relationship with same relationship name?
Re: Reflexive relationship with same relationship name?
- Subject: Re: Reflexive relationship with same relationship name?
- From: Farrukh Ijaz <email@hidden>
- Date: Sun, 11 Jul 2010 21:33:06 +0300
Very important point highlighted by Chuck. EOF is very efficient in maintaining all types of relations including recursive. You must becareful of cyclic reference as it may lead into stack overflow situation. Also make sure your model should care of the delete rule otherwise... I just deleted my account but the whole network is gone :)
I think wonder would have provided something to avoid cyclic fetch.
Farrukh
Sent from my iPad
On 11-Jul-2010, at 9:07 PM, Chuck Hill <email@hidden> wrote:
> I think that should be fine. You might want to plan out how you are going to qualify this for fetches.
>
>
>
> On Jul 10, 2010, at 2:25 PM, Joe Moreno wrote:
>
>> Is it possible for EOF to support a reflexive relationship back to the same Entity with the same relationship property name through a flattened many-to-many?
>>
>> Think of a User entity in the case of LinkedIn where users are "linked" to other users:
>> User <---->>Connection<<---->User
>>
>> Connection is the flattened (EOGenericRecord) m:n table with only the foreign keys as its two primary keys. User.connections simply returns all the connected users.
>>
>> I'm imagining that you'd link them up like this:
>> userA.addObjectToBothSidesOfRelationshipWithKey(userB, "connection");
>>
>> Any one with experience/gotchas doing this? (No inheritance involved.)
>>
>> Thanks,
>> Joe
>> _______________________________________________
>> Do not post admin requests to the list. They will be ignored.
>> Webobjects-dev mailing list (email@hidden)
>> Help/Unsubscribe/Update your Subscription:
>>
>> This email sent to email@hidden
>
> --
> Chuck Hill Senior Consultant / VP Development
>
> Practical WebObjects - for developers who want to increase their overall knowledge of WebObjects or who are trying to solve specific problems.
> http://www.global-village.net/products/practical_webobjects
>
>
>
>
>
>
>
> _______________________________________________
> Do not post admin requests to the list. They will be ignored.
> Webobjects-dev mailing list (email@hidden)
> Help/Unsubscribe/Update your Subscription:
>
> This email sent to email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden