When dealing with schema updates in MySQL I often have to check what foreign key constraints are in place. How can we find which table have columns that reference the primary column on the table we’re modifying. Here’s the SQL statement that will help us find those references.
REFERENCED_TABLE_SCHEMA = 'database_name' AND
REFERENCED_TABLE_NAME = 'table_name';