整个数据库查找 placement 字段: select * from INFORMATION_SCHEMA.columns where COLUMN_NAME Like '%placement%'; 根据 Database 数据库 查看 ColumnA,ColumnB字段: SELECT DISTINCT TABLE_NAME FROM INFORMATION_SCHEMA.COLUMNS WHERE COLUMN_NAME IN ('ColumnA','ColumnB') AND TABLE…
对以"db_1"开头的数据库进行授权 grant all privileges on `db_1%`.* to dp_admin identified by 'password'; grant select on `db_1%`.* to dp_admin identified by 'password';…
查询tablename 数据库中 以"_copy" 结尾的表 select table_name from information_schema.tables where table_schema='tablename' and table_type='base table' and table_name like '%_copy'; information_schema 是MySQL系统自带的数据库,提供了对数据库元数据的访问information_schema.tables 指数据…
--查询tablename 数据库中 以"_copy" 结尾的表 select table_name from information_schema.tables where table_schema='tablename' and table_type='base table' and table_name like '%_copy'; --information_schema 是MySQL系统自带的数据库,提供了对数据库元数据的访问 --information_schema.tab…