I had my database working but all the records I have inserted were for checking purpose, now I wanted to delete all the tables and creating new ones, so I tried updating the dat
The documentation says:
If foreign key constraints are enabled, a DROP TABLE command performs an implicit DELETE FROM command before removing the table from the database schema. […] If the implicit DELETE FROM executed as part of a DROP TABLE command violates any immediate foreign key constraints, an error is returned and the table is not dropped.
Remove the data in the correct order so that all intermediate steps are valid. Or just disable foreign constraint checking (db.setForeignKeyConstraintsEnabled()
).