Re: Help on big relationship
Re: Help on big relationship
- Subject: Re: Help on big relationship
- From: Wolfram Stebel <email@hidden>
- Date: Fri, 12 May 2006 23:18:11 +0200
- Thread-topic: Help on big relationship
Am 12.05.2006 22:11 Uhr schrieb "Kieran Kelleher" unter
<email@hidden>:
> OK, I've seen how to deal with this in the past somewhere on a WWDC
> video or something, but for the life of me I cannot find the approach
> right now and I am under the crunch to get this done.
>
> I have DataList objects with up to a million related DataRecord
> objects. DataList and DataRecord are related in a many-to-many join.
> Usually a DataRecord belongs to no more than 50 DataLists.
>
> So regular dataList.dataRecords() obviously crashes my app when huge
> amount of data records in the relationship.
>
> Am I understanding correctly in saying that fetching my one DataList
> with a million related DataRecords will create a million "faults"?
>
> What is the strategy here?
>
> Is it:
> - turn off the dataRecords class property visibility (diamond icon)?
> - kill the relationship to dataRecords in the DataList entity and
> work with qualifiers, fetchspecs and raw rows to grab dataRecords as
> needed? How does this affect creating relationships .... just always
> add the DataList to the DataRecord's dataLists relationship?
>
> Any best practice tips, pointers or links to same would be appreciated.
>
Hi Kieran
you already received valuable input to this problem.
But let me try to explain a little different.
Always when you are aware of masses of data, you should never expect
automatisms to be the perfect solution.
This sounds a little of wrong planning. If you know you have masses of data,
there should be some very extraordinary reason to fetch them all at once,
automatically or not. I can't find a reason, while writing this :-) you
wouldn't create a report via EO this way, would you?
Based on your knowledge of quantities start planning another way.
Try to segment your data on secondary attributes so that you never have tons
of data.
I would recommend to use custom fetch specifications for this always, based
on primary criteria and restrictions from user input.
The user should be the limiting "entity" here. The user is never able to
review millions of datasets, nor to read a report of this size...
As you can see, i have no fast solution for you...
But THINK!
Kind regards
Wolfram
_______________________________________________
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