Created
February 17, 2011 21:35
-
-
Save yellow5/832761 to your computer and use it in GitHub Desktop.
An example of a quick way to list tables in a database containing a given column name
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
select table_name | |
from `information_schema`.`columns` | |
where table_schema = 'DB_NAME' and column_name = 'DESIRED_COLUMN_NAME'; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment