Reputation: 117
How can I copy sqlite file back to main bundle after updating the database? Now I copy sqlite file into Documents directory, insert new records than select all from it, and I can see that the data is there, old and new one. How to update the main database which I copied? Thank you for your time and help.
Upvotes: 0
Views: 281
Reputation: 113
Actually you cannot change the app bundle files. Once you changed the app bundle files it invalidates the app sign and it will install anymore. You have to copy the app bundle files to App Documents directory and always use the files in documents directory.
https://stackoverflow.com/a/4764638/5019395
Upvotes: 2
Reputation: 5148
No you can't copy sqlite file back to main bundle because app bundle is read-only!
Upvotes: 1