We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 1cfdd06 + 7349e17 commit 19deaa6Copy full SHA for 19deaa6
show-foreign-keys
@@ -0,0 +1,8 @@
1
+#!/bin/bash
2
+mysql -u root -p <<EOT
3
+use INFORMATION_SCHEMA;
4
+
5
+select TABLE_NAME,COLUMN_NAME,CONSTRAINT_NAME,
6
+REFERENCED_TABLE_NAME,REFERENCED_COLUMN_NAME from KEY_COLUMN_USAGE where
7
+REFERENCED_TABLE_NAME = '$1';
8
+EOT
0 commit comments