I think this is expected behavior on the mysql side. Here is a note I got from @costinmoraru:
Foreign key constraint names that point to the renamed table are automatically updated unless there is a conflict, in which case the statement fails with an error. A conflict occurs if the renamed constraint name already exists. In such cases, you must drop and re-create the foreign keys for them to function properly.
https://dev.mysql.com/doc/refman/5.7/en/rename-table.html
official mysql doc
Does that help resolve the issue @tremmie?
(thanks also to @hope99 for moving the issue forward too ![]()
-Ronak