So I cannot directly filter an array of dictionaries using a predicate? That was the whole goal of my question, see my original post.
- Koen. On Oct 15, 2012, at 6:33 AM, Willeke <willeke2...@gmail.com> wrote: > > Op 15 okt 2012, om 02:05 heeft Koen van der Drift het volgende geschreven: > >> >> On Oct 14, 2012, at 7:56 PM, Willeke <willeke2...@gmail.com> wrote: >> >>> the predicate should be something like >>> name IN {"Jones A.", "Williams S.", "Brown M.", "Tobias S."} >>> >>> what is persons in this statement? >>> [fetchRequest setPredicate: [NSPredicate predicateWithFormat: @"name IN >>> %@", persons]]; >> >> 'persons' is an array of dictionaries, where one of the key-value pairs >> contains the name. >> >> - Koen. > > It should be an array of strings: > [fetchRequest setPredicate: [NSPredicate predicateWithFormat: @"name IN %@", > [persons valueForKey:@"name"]]]; > > Willeke > _______________________________________________ > > Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) > > 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: > https://lists.apple.com/mailman/options/cocoa-dev/koenvanderdrift%40gmail.com > > This email sent to koenvanderdr...@gmail.com _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) 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: https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com