• 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: Filtered to many relationship
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Filtered to many relationship


  • Subject: Re: Filtered to many relationship
  • From: Chuck Hill <email@hidden>
  • Date: Thu, 1 May 2008 21:10:53 -0700


On May 1, 2008, at 7:31 PM, Steve Peery wrote:

I am trying to set up a to many relationship in Entity Modeler that filters
the destination objects based on a variable in the destination object.


For example, in my School object I have an array of Student objects some
have a variable that defines them as fulltime. Now in my School object I
want to create a to many relationship that just contains the Student objects
that are fulltime. How is this done?


It is not. At least not without some rather clever work in your EO class. The "normal" way to do this is to add a method to your EO class, something like this:

public NSArray fulltimeStudents() {
return EOQualifier. filteredArrayWithQualifier(students(), <your full-time student qualifier here>);
}



Chuck


--

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


  • Follow-Ups:
    • Re: Filtered to many relationship
      • From: Mike Schrag <email@hidden>
    • Re: Filtered to many relationship
      • From: Pierre Bernard <email@hidden>
    • Re: Filtered to many relationship
      • From: Don Lindsay <email@hidden>
References: 
 >Filtered to many relationship (From: Steve Peery <email@hidden>)

  • Prev by Date: Re: Detect SSL
  • Next by Date: Re: Detect SSL
  • Previous by thread: Filtered to many relationship
  • Next by thread: Re: Filtered to many relationship
  • Index(es):
    • Date
    • Thread