Upgrading Android App with pre-built database.

I have an Android App with a pre-built SQLite DB packaged with it. However, I'm sure that if I want to do an upgrade with an upgraded/altered/new database it will be tricky. I found this out on my emulator and handset. When I changed DBs (keeping the name the same, or altered the DB and put it back into the assets directory, and then ran the app on the emulator, it wouldn't read the new DB, but would keep the old database. The only way to get rid of the old DB, it seems, is to delete the app and reinstall it. WHich is what I do when I test my apps on my handset after changing the database. Another option is to change the name of the database, and all references to it in the code, but this doubles the database storage of the app and wastes space.
Can't you just drop the old database, or the relevant tables, then import your new sql data?

以上就是Upgrading Android App with pre-built database.的详细内容,更多请关注web前端其它相关文章!

赞(0) 打赏
未经允许不得转载:web前端首页 » JavaScript 答疑

评论 抢沙发

  • 昵称 (必填)
  • 邮箱 (必填)
  • 网址

前端开发相关广告投放 更专业 更精准