SQLite Forum

Bug in ALTER TABLE ADD COLUMN
Login
If the table is empty, you can also just adjust the schema directly in the `sqlite_master` table (although you must then close and reopen the database before using that table; if you do not, then it can cause problems). (This also works to make other adjustments to the schema, although you should not add or remove tables in this way, nor should you touch the page numbers; if adjusting a table or index which contains data, then you must be more careful; read the file format documentation before attempting to adjust anything in the `sqlite_master` table at all, or else you will probably break it.)