SQLite Forum

DROP COLUMN feature with indexes
> Do you have a rationale for why you prefer fail to drop?

Yes.  The use of a DDL command should not result in an invalid schema unless you have specified that this is the result you intend.

 > To me that is like asking the user to manually delete triggers before dropping a table.

No, it is not.  If you drop a table then all triggers which apply to that table (as in specified in the ON clause) should be dropped because they are entirely no longer applicable.

Table names being dropped that are used in the body of a view or trigger that is not ON that table should act to prohibit the table from being dropped unless the user has indicated that they wish to allow an inconsistent schema result (pragma legacy_alter_table).

Column names being dropped that are referenced in a view or trigger body (or in an index) should also cause the drop of the column name to fail with an error rather than leaving the schema in an inconsistent state UNLESS one has specifically enabled the option for allowing an inconsistent schema (pragma legacy_alter_table).