In my CoreData app, all inverse many-to-many relationships have a relationship fault. -- observed using NSLog(@"%@", [self description])
. The fault appears after data is saved and subsequently opened.
The relationship delete rule might be the culprit.
Here is an example.
Person
friends<<--->> (An inverse many-to-many relationship on self.
addresses<<--| (A many-many relationship to Address
|
Address |
owners<<-----| (A many-many relationship to person.address Addresses can be shared
The Address.owners
relationship is set to deny.
The Person.addresses
relationship is set to nullify.
The Person.friends
relationship is set to deny.
I'd appreciate some clarification:
Given an easier case, where address is NOT shared.
AddressBoook Person Address
people-------->addresses---->>owner
Person.address
is set to Nullify. (Remove the address(es) only when the owner is removed)
the Address.owner is set to .... No action. (Dont want to delete the person. Or nullify? Because Person is still held by AddressBook object
- What are we deleting, the relationship or the owning object.
- In a many-many relationship, can we consider, Nullify to occur on the removal of the last object -- or the first one and thus dangling those others in space. It must be the deletion of the Set!.
Thanks