sql语句
select table_schema , table_name , table_rows , table_comment ,
(select GROUP_CONCAT(COLUMN_NAME) from information_schema.columns a where table_schema ='wdl_base' and a.table_name = b.table_name) COLUMN_NAME ,
(select REPLACE(GROUP_CONCAT(column_comment),',,','') from information_schema.columns a where table_schema ='wdl_base'
and a.table_name = b.table_name) column_comment
from information_schema.tables b where table_schema='wdl_base' and table_type='base table';
该SQL语句用于获取名为wdl_base的数据库中的所有基表的详细信息,包括表架构,表名,行数,表注释,以及每个表的所有列名和列注释。
3298

被折叠的 条评论
为什么被折叠?



