3 ms·
> "For searching for items with '%foo%' in all tables and columns" To do this you could perform two queries of the information_schema (one query for '%foo%' in
by ZenoArrow 10y ago
> "For searching for items with '%foo%' in all tables and columns"
To do this you could perform two queries of the information_schema (one query for '%foo%' in tables, one query for '%foo%' in columns) and join them together with a UNION statement (or if you didn't mind duplicates you could use UNION ALL in this case as it's faster and the results from both queries can have the same fields).