I have a data model I'm trying to port from a SQLite based table structure to a Core Data model. My SQLite structure has a Zones table and a TransitLogs table. A TransitLog can have the following (in my sqlite schema) start_zone_id end_zone_id
Each of which is a foreign key to the zones table. This works fine in SQL. But when moving to Core Data I'm having trouble understanding how to model this.
My first attempt has me having two relationships in my TransitLog Entity with a startZone and endZone relationship attributes that point to a Zone (sorry wasn't able to post a screenshot of xcode as this is my first post here)
The question I have is how to handle the inverse relationship for the startZone and endZone relationship attributes. Do I not need them? In the documentation and books I've read on this topic, it's best to always use an inverse relationship but I'm wondering about this particular situation if it doesn't apply. Or am I simply modeling this incorrectly in Core Data.
Thanks for any advice.
Mike