Last active
December 30, 2019 11:49
-
-
Save Hazem-Ben-Khalfallah/8ef79134a5bc2a35ff80256e3e188136 to your computer and use it in GitHub Desktop.
[Show all table constraints] #sql
This file contains hidden or 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
| SELECT TABLE_NAME, | |
| COLUMN_NAME, | |
| CONSTRAINT_NAME, | |
| REFERENCED_TABLE_NAME, | |
| REFERENCED_COLUMN_NAME | |
| FROM information_schema.KEY_COLUMN_USAGE | |
| WHERE TABLE_NAME = "<TABLE_NAME>"; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment