How to reset SqLite database in Android?

前端 未结 6 922
一个人的身影
一个人的身影 2021-01-03 21:13

I want my users to be able to reset the application, then I need to reset the SQLite database that I have created. How can I do that? I want to reset the database or delete

6条回答
  •  生来不讨喜
    2021-01-03 22:09

    Just drop tables from database

    db.execSQL("DROP TABLE "+TABLENAME);
    

    and again create the table in same database.

提交回复
热议问题