查看所有表和表注释
select
table_name,
table_comment
from
information_schema.tables
where
table_schema = '某数据库名称'
information_schema.tables: 表的字段信息
table_schema,table_name,create_time,update_time,check_time,table_comment
查看所有字段和字段注释
select
column_name,
column_comment
from
information_schema.columns
where
table_name = '表名'
and table_schema='数据库名'
INFORMATION_SCHEMA.Columns:列的信息
TABLE_SCHEMA,TABLE_NAME,COLUMN_NAME, COLUMN_TYPE, COLUMN_KEY
网友评论