Skip to content

Instantly share code, notes, and snippets.

@jamesstacyjones
Last active December 26, 2015 18:39
Show Gist options
  • Save jamesstacyjones/7196145 to your computer and use it in GitHub Desktop.
Save jamesstacyjones/7196145 to your computer and use it in GitHub Desktop.
find foreign key constraint errors.
SELECT constraint_name, table_name FROM information_schema.table_constraints WHERE constraint_type = 'FOREIGN KEY' AND table_schema = DATABASE() ORDER BY constraint_name;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment