0

Is it possible to delete a column from an SQLlite database. I have Googled this and it seems to be impossible.

woz
  • 10,888
  • 3
  • 34
  • 64
user2461593
  • 87
  • 1
  • 8
  • possible duplicate of [How to delete or add column in SQLITE?](http://stackoverflow.com/questions/8442147/how-to-delete-or-add-column-in-sqlite) – woz Jun 12 '13 at 17:28
  • possible duplicate of [Delete column from SQL table](http://stackoverflow.com/questions/5938048/delete-column-from-sql-table) – woz Jun 12 '13 at 17:31

2 Answers2

0

According to the docs:

It is not possible to rename a column, remove a column, or add or remove constraints from a table.

I guess it has to be done manually.

woz
  • 10,888
  • 3
  • 34
  • 64
0

From the ALTER TABLE manual;

SQLite supports a limited subset of ALTER TABLE. The ALTER TABLE command in SQLite allows the user to rename a table or to add a new column to an existing table. It is not possible to rename a column, remove a column, or add or remove constraints from a table.

So, no, not without dropping and recreating the table.

Joachim Isaksson
  • 176,943
  • 25
  • 281
  • 294