ITPub博客

首页 > 数据库 > MySQL > Mysql查询数据字典

Mysql查询数据字典

原创 MySQL 作者:drgfml 时间:2018-07-20 13:39:05 0 删除 编辑

SELECT

        a.TABLE_NAME as tableName,

b.TABLE_COMMENT as tableComment,

        a.COLUMN_NAME as columnName,

        a.COLUMN_COMMENT as columnComment,

        a.COLUMN_TYPE as columnType,

        null as length,

        null as scale,

        a.IS_NULLABLE as isNullable

        from information_schema.COLUMNS a

        LEFT JOIN information_schema.TABLES b ON a.TABLE_NAME=b.TABLE_NAME

        where a.TABLE_SCHEMA='hbsm' and a.TABLE_NAME 

in('t_sm_saleapply_benef_status')

order by a.TABLE_NAME


来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/96210/viewspace-2158212/ ,如需转载,请注明出处,否则将追究法律责任。

请登录后发表评论 登录
全部评论
  • 博文量
    32
  • 访问量
    59160