I am using Core Data and have a two entity setup that in a simple form could be modelled something like this:
Entity: Persons - attribute: name - attribute: birth - relationship: cars (one to many with cars) Entiry: Cars - attribute: name I would like to search for all persons not born on the date varDate that have cars. I can do the search for all records/objects where the date in the attribute birth is not equal to varDate, I can do this with something like: [request setPredicate:[NSPredicate predicateWithFormat:@"birth != %@", self.varDate]]; but I am having difficulty figuring out how to write the predicate for the relationship data, I would like something like: [request setPredicate:[NSPredicate predicateWithFormat:@"cars != %@", NULL]]; Could someone help me write this predicate and show me the best way to combine it with the first predicate? Thanks Greg _______________________________________________ Cocoa-dev mailing list ([email protected]) 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: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to [email protected]
