how to drop database in sqlite?

前端 未结 8 1173
终归单人心
终归单人心 2020-12-03 17:05

I\'m using SQLite in android. I want to drop the database.

For example: mysql- drop database dbname

How do I implement this code in SQLite?

8条回答
  •  情话喂你
    2020-12-03 17:32

    You can drop tables by issuing an SQL Command as you would normally. If you want to drop the whole database you'll have to delete the file. You can delete the file located under

    data/data/com.your.app.name/database/[databasefilename]

    you can do this from the eclipse view called "FileBrowser" out of the "Android" Category for example. Or directly on your emulator or phone.

提交回复
热议问题