Reputation: 3349
So basically I have a lot of static data in an existing Android app and I am trying to make a version of that app in iOS that uses Core Data.
I'd like to know how to use the existing Android DB file and migrate the data over programmatically.
I'd just really like to stay away from the sqlite3 stuff in iOS if possible.
Please let me know if this is possible
Upvotes: 1
Views: 368
Reputation: 18363
There is no easy, one-size-fits-all approach to this. In general, these are the steps you'll want to follow:
NSManagedObject
s and populate the attributes and relationships that you identified earlier.Unfortunately, there will be no way to avoid writing some code to interact with your existing database. If you wish to avoid writing C code to do so, you can check out an Objective-C library that provides an interface to the SQLite routines that's more object-oriented called FMDB.
Upvotes: 2