I'm modeling a relationship in Core Data where an object Foo can have multiple Item's and an Item cannot exist without a Foo.
In the Core Data model, I have object Foo which has an optional to-many relationship named "items" to object Item where the delete rule is to cascade. Each Item has a non-optional inverse relationship back to Foo named "foo" where the count = 1 and the delete rule is set to nullify.
Currently,
foo.items = newItems;
results in the inverse relationship to Foo being nil'd for each of the old items. Is there a way to setup Core Data to preserve the inverse relationship on the old items (so they still point back to foo)?
foo.itemsto contain all of the old values initemsplus all of the new ones innewItems? - Tom Harrington