i have the sqlite db and want to convert into core data model. i also have a look at SqliteToCoredata given in githhub but unable to use properly. so is there any easy way to do that conversion. additionally i also have csv file. is there any way to convert csv file to core data model.
1 Answer
Of course there's a way. There just isn't any automatic way. You'll need to
- Load your existing data
- Iterate over each entry
- For each entry, create a corresponding managed object.
If you're using CSV, you can load the file into an NSString (if it isn't too big) and then iterate over each line. If you're using SQLite, you'll need to use either the SQLite API or one of the ObjC-style wrappers like FMDB or PLDatabase.