I am running a huge database with so many tables and tables are having so many columns.
My DB is MySQL and I have to search for a particular column.
Is there a way available in MySQL to search a column name from all tables in a database?
Retrieve it from INFORMATION_SCHEMA COLUMNS Table
Query
select table_name, column_name
from information_schema.columns
where column_name like '%search_keyword%'; -- change search_keyword accordingly
Or if you want to search for exact column name then no need of LIKE
.
where column_name = 'column_name_to_be_find';
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With