• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: restricting qualifiers and join entities
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: restricting qualifiers and join entities


  • Subject: Re: restricting qualifiers and join entities
  • From: Lachlan Deck <email@hidden>
  • Date: Wed, 4 Jun 2008 13:19:17 +1000

On 04/06/2008, at 12:58 PM, Chuck Hill wrote:

On Jun 3, 2008, at 7:26 PM, Lachlan Deck wrote:

Hi there,

Say I have entities Foo and Bar (both of which have an attribute isDeleted) and a join FooBar and I create restricting qualifiers for Foo and Bar of (isDeleted IS NULL OR isDeleted = 0).

Foo.fooBars() still fetches all fooBars even if pointing to a Bar that cannot be instantiated due to the restricting qualifier.

So my question is: should EOF filter such joins automatically (i.e., should I file a bug) or is it just up to me to auto-apply these restricting qualifiers?

I would expect that to work for fetches. In the past I have had a relationship to a subclass in a single table inheritance hierarchy, and I recall that only the correct instances were fetched.

Yeah, and I just checked again and I already have code that automatically creates a restricting qualifier for joins by migrating the restricting qualifiers from the related entities. So I end up with:


9837 INFO [main] (er.extensions.ERXNSLogLog4jBridge, appendln, 38) -
willLoadEntity added restricting qualifier to:FooBar of ((foo.isDeleted <> (java.lang.Boolean)'true') and (bar.isDeleted <> (java.lang.Boolean)'true'))


But maybe the problem is that of null results for these related entities where the qualifier applies.

I can't see why this should not work, I'd file a bug.

ok.

Have you checked the SQL and verified that they restricting qualifier is not getting generated?

Will have to check again. Thanks.

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


  • Follow-Ups:
    • Re: restricting qualifiers and join entities
      • From: Lachlan Deck <email@hidden>
References: 
 >restricting qualifiers and join entities (From: Lachlan Deck <email@hidden>)
 >Re: restricting qualifiers and join entities (From: Chuck Hill <email@hidden>)

  • Prev by Date: Re: restricting qualifiers and join entities
  • Next by Date: Re: restricting qualifiers and join entities
  • Previous by thread: Re: restricting qualifiers and join entities
  • Next by thread: Re: restricting qualifiers and join entities
  • Index(es):
    • Date
    • Thread