ios - Core Data: Database not reading correctly -


i'm trying load nsdata core data database data isn't remotely close what's displaying if compare 2 files, original database vs 1 saved nsdata loaded, , 1 saved nsdata doesn't have data in @ all, table structure.

here's source, , it's extremely basic:

nsmanagedobjectcontext *managedobjectcontext = self.managedobjectcontext;     if (managedobjectcontext != nil) {         nserror *error = nil;         if ([managedobjectcontext haschanges] && ![managedobjectcontext save:&error]) {             // replace implementation code handle error appropriately.             // abort() causes application generate crash log , terminate. should not use function in shipping application, although may useful during development.             nslog(@"unresolved error %@, %@", error, [error userinfo]);             abort();         }     }  nsstring *path = [appdelegate instance].databasedirectory.path; nsdata *file   = [[nsfilemanager defaultmanager] contentsatpath:path]; [file writetofile:[appdelegate instance].tempdatabasedirectory.path atomically:no]; 


Comments

Popular posts from this blog

node.js - Mongoose: Cast to ObjectId failed for value on newly created object after setting the value -

[C++][SFML 2.2] Strange Performance Issues - Moving Mouse Lowers CPU Usage -

ios - Possible to get UIButton sizeThatFits to work? -