• 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: Two tables walk into an EO model...
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Two tables walk into an EO model...


  • Subject: Re: Two tables walk into an EO model...
  • From: email@hidden (Anjo Krank)
  • Date: Sun, 3 Aug 2003 12:13:33 +0200
  • Xx-reply-to: email@hidden

Am Sonntag, 03.08.03, um 11:31 Uhr (Europe/Berlin) schrieb Goodbye Bill:

Using this example above, I need to find all Employees based on the
following criteria:

    1. Employee must be female; and
    2. Office must be located in the 06492 postal code

How in the world does one do this?

Assuming that you have a flattened EmployeeOffice join entity (created with the EOModeler > Property >"Join in Many To Many" command), which should be named "offices" in the employee you construct the qualifier with:


EOQualifier q = EOQualifier.qualifierWithQualiferFormat("gender = 'f' and offices.postalCode = '06492'");

Further assuming that you already have an array "allEmployees" you can also say:

NSArray mathes = EOQualifier. filteredArrayWithQualifier(allEmployees, q);

which should answer your other question...

Cheers, Anjo
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.

References: 
 >Two tables walk into an EO model... (From: Goodbye Bill <email@hidden>)

  • Prev by Date: Re: Learning Mac programming
  • Next by Date: Re: EO: Filtering Existing Objects
  • Previous by thread: Two tables walk into an EO model...
  • Next by thread: Re: Two tables walk into an EO model...
  • Index(es):
    • Date
    • Thread