I have a problem related to the app that I developed which runs on honeycomb. When I reinstall the apk its database gets deleted. There did not used to be this almost 1 week ago. Why this is happening now? What can cause db to be deleted and how to prevent it?
Share
I think, If your database stored in application’s internal storage
/data/data/<package_name>/databases/then when your application un-installed from device, all directories with your application package are removed from the device this cause your database removed.To prevent put your database copy in application’s
/assetdirectory so whenever your application first time runt it copy the database from asset to internal storage path. And you can access it whenever application re-installed, also you can put your database in/sdcardbut user can also delete it..EDIT: Using your own SQLite database in Android applications and How to ship an Android application with a database?
Thanks…