I encountered a foreign key constraint error when trying to roll back my database migration.
In case anyone encountered this problem too, I fixed it by adding the following to the _update_tags_table.php migration file:
public function down()
{
Schema::disableForeignKeyConstraints();
Schema::table('tagging_tags', function ($table) {
$table->dropForeign('tagging_tags_tag_group_id_foreign');
$table->dropColumn('tag_group_id');
});
}
You might want to update the package with these new lines to avoid the error.
I encountered a foreign key constraint error when trying to roll back my database migration.
In case anyone encountered this problem too, I fixed it by adding the following to the
_update_tags_table.php
migration file:You might want to update the package with these new lines to avoid the error.