• 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
Filtering an NSArrayController using a to-many relationship
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Filtering an NSArrayController using a to-many relationship


  • Subject: Filtering an NSArrayController using a to-many relationship
  • From: Danny Greg <email@hidden>
  • Date: Thu, 25 Sep 2008 17:06:35 +0100

Hi list,

In my data model 2 of my enities are "Snap" and "Tag" and they have a many-to-many relationship between them.

My UI is controlled by an NSArrayController bound to the Snap entity, I have a search field that sets the filter predicate of this NSArrayController (through code not bindings for various reasons). The array controller needs to be filtered to show any "snaps" which have a tag that matches the search field's string value.

Tag has an attribute of "title" so I tried a straight forward predicate such as ANY tags.title like [search string] (where "tags" is the relationship on the Snap entity). But this fails every time.

There seem to be a lot of unanswered messages in the archives regarding this, can someone tell me what I'm missing?

Thanks

Realmac Software
Danny Greg, Cocoa Junior

We are Realmac Software. We make nice things for Apple Macs.

Website: www.realmacsoftware.com

Office 4, 100 North Road
Brighton, BN1 1YE
United Kingdom



_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: Filtering an NSArrayController using a to-many relationship
      • From: "I. Savant" <email@hidden>
  • Prev by Date: Re: What does @loader_path refer to when loading ibplugins from a linked-in framework?
  • Next by Date: Re: How to set up a thread listening to performSelector: messages?
  • Previous by thread: Re: How to set up a thread listening to performSelector: messages?
  • Next by thread: Re: Filtering an NSArrayController using a to-many relationship
  • Index(es):
    • Date
    • Thread