Re: Avoiding nulls along an EOQualifier's [toMany] keypaths
Re: Avoiding nulls along an EOQualifier's [toMany] keypaths
- Subject: Re: Avoiding nulls along an EOQualifier's [toMany] keypaths
- From: Lachlan Deck <email@hidden>
- Date: Tue, 14 Nov 2006 10:40:40 +1100
Hi Jerry,
On 13/11/2006, at 11:08 PM, Jerry W. Walker wrote:
Couldn't you override valueForKeyPath in C to do a valueForKeyPath
for the D within a try/catch block and catch the exceptions?
That'd be too simple, Jerry ;-) That'll work for this case (where the
filtering is in-memory).
It'd be good to know of a way to build a qualifier that'd also work
database queries... or better, some kind of sub-EOFetchSpecification
that can be used as a result set (like sub-queries in sql) for
another fetchSpec within the one fetch.
Cheers.
On Nov 13, 2006, at 2:01 AM, Lachlan Deck wrote:
Hi there,
I have some entities related as follows...
A -->> B -->> C --> D
...and a qualifier...
new EOKeyValueQualifier( "b.c.d",
EOQualifier.QualifierOperatorContains, myD );
...used for a display group to limit the view to those 'a' objects
that contain any 'b's that have a relationship to any 'c' that is
related to a particular 'd'.
The trouble is that some c's may have a null relationship for d.
So, obviously, where relevant NSKeyValueCoding.NullValue's get
substituted which cannot resolve the key "d"; and an exception is
thrown.
Does anyone have any efficient work-a-rounds?
There's potentially a lot of objects involved - so it'll need to
be somewhat efficient.
Thanks in advance...
with regards,
--
Lachlan Deck
--
__ Jerry W. Walker,
WebObjects Developer/Instructor for High Performance Industrial
Strength Internet Enabled Systems
email@hidden
203 278-4085 office
with regards,
--
Lachlan Deck
_______________________________________________
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