My iOS app is using NSCoreData
and stores lots of data in the database. I designed the database schema in *.xcdatamodeld
file in xcode. I am planning to update my application soon and need to change the schema a little. However, when I tested it, new version is removing all old data, saved in previous version.
How can I effectively migrate to new database schema without loosing old data in the app? I tried to google for a suitable solution, but could not find any effective idea, how to do it.