How do I delete column from sqlite table in android?

前端 未结 2 1951
情深已故
情深已故 2020-12-24 07:10

I tried deleting a column by using the following

openDB.execSQL(\"ALTER TABLE favs\" + \" DROP COLUMN favsCount\");

LogCat gives the follow

2条回答
  •  礼貌的吻别
    2020-12-24 07:37

    as mu is too short says Sqlite doesn't allow to do an alter table to delete a column. here you can see the alter syntax definition

提交回复
热议问题