I have two tables, Parent and Child. The column Parent.favorite_child has a foreign key constraint pointing to Child.id. And the column Child.parent has a foreign key constraint pointing to Parent.id.
Now here's the weird part. I'm trying to drop my Child table, which contains no records, but MySQL is giving me the error:
ERROR 1217: Cannot delete or update a parent row: a foreign key constraint fails
SQL Statement:
drop table `mydatabase`.`Child`
Why is MySQL throwing this error? There are literally no records in the Child table with which anything could be pointing to or from.