Last active
August 29, 2015 13:56
-
-
Save clairtonluz/9072360 to your computer and use it in GitHub Desktop.
showForeignKeys
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
use INFORMATION_SCHEMA; | |
select TABLE_NAME,COLUMN_NAME,CONSTRAINT_NAME, | |
REFERENCED_TABLE_NAME,REFERENCED_COLUMN_NAME from KEY_COLUMN_USAGE where | |
REFERENCED_TABLE_NAME = 'nomeDaTabelaPai'; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment