When I save the context of a managed data object in iOS 6.0.1 to SQLite repository, I run the strange exception "CoreData does not maintain a constant relationship between repositories." This is a one-to-one relationship between quotes and abstract sources in the model. At run time, this applies to the quote and book (where the book is inherited from AbstractSource. Everything works well in the model editor.)
I investigated similar reports and examined the reasons given:
- I assign both the quote and the book to the same persistent store using assignObject: toPersistentStore :, so that no unassigned ones remain.
- The error description shows that all the "absolute" x-coredata identifiers begin with the same prefix (for example, "x-coredata: // 82B3BEB3-60F2-4912-AC80-11AAD29CFF99 /", so it really seems there that only one store is used .
My questions are as follows:
- Is there anything else I need to check (maybe sg. In relation to AbstractSource, which I don’t touch / control in my source? I'm creating both a quote and a book calling initWithEntity: insertIntoManagedObjectContext each.)
- I noticed that the error description also includes several "relative" x-coredata ids (forms of "x-coredata: /// ..."). Could that absolute form always be considered as a "cross-database", even if the "absolute" prefixes (see example above) are the same? And if so, how can I influence any choice between the “absolute” and “relative” x-coredata identifiers?
Thank you (a lot) for your attention!
Drux
source share