Created
August 17, 2022 17:31
-
-
Save devCcori/7ee313ce2cc739019e7879880d583e16 to your computer and use it in GitHub Desktop.
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 t.table_schema, | |
t.table_name | |
from information_schema.tables t | |
inner join information_schema.columns c on c.table_name = t.table_name | |
and c.table_schema = t.table_schema | |
where c.column_name = 'COLUMN_TO_FIND' | |
and t.table_schema not in ('information_schema', 'pg_catalog') | |
and t.table_type = 'BASE TABLE' | |
order by t.table_schema; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Scritp to find a column in a Postgres Database