开发者

iPhone CoreData Migration and modifying data

开发者 https://www.devze.com 2022-12-31 23:46 出处:网络
I have an app that has both static data and user entered data in the CoreData store. I understand how to do a lightweight migration to a new database version, but how to I add or modify the static dat

I have an app that has both static data and user entered data in the CoreData store. I understand how to do a lightweight migration to a new database version, but how to I add or modify the static data without affecting the users data?

If I have 50 static data entries to add and a couple to modify (ie. spelling mistakes) should they be stored in a different sqlite db and copied over? Also, is it possible to look at the version of the data store so that this copy only开发者_StackOverflow happens the first time the app is started up after upgrading?

Sorry for the general noob type question, but this is the first time I have ever had to deal with this sort of issue.

Thanks,

Scott


Your question is mostly a duplicate of a previous one of mine:

iPhone and Core Data: how to retain user-entered data between updates?

At least until you can specify exactly what form your static data and dynamic data take, and if any static data refers to dynamic data or vice versa.

0

精彩评论

暂无评论...
验证码 换一张
取 消