Skip to content

Instantly share code, notes, and snippets.

@ffeast
Created July 18, 2016 12:29
Show Gist options
  • Save ffeast/6811f4c23fbaee3667f05a0cc46a8067 to your computer and use it in GitHub Desktop.
Save ffeast/6811f4c23fbaee3667f05a0cc46a8067 to your computer and use it in GitHub Desktop.
Tables in the current mysql db containing the specified column
SELECT
DISTINCT table_name
FROM
information_schema.columns
WHERE
column_name IN ('your_column')
AND table_schema=(select database());
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment