SELECT DISTINCT
TAble_NAME
FROM
information_schema.`COLUMNS`
WHERE
COLUMN_NAME = '字段名'
AND TABLE_SCHEMA = '数据库名'
AND TABLE_NAME NOT LIKE 'vw%'
查询数据库中包含某个字段的所有表
最新推荐文章于 2023-10-13 10:44:39 发布
SELECT DISTINCT
TAble_NAME
FROM
information_schema.`COLUMNS`
WHERE
COLUMN_NAME = '字段名'
AND TABLE_SCHEMA = '数据库名'
AND TABLE_NAME NOT LIKE 'vw%'