mysql 查询表字段信息(字段名、描述、类型、长度)

/ 默认分类 / 没有评论 / 9760浏览
select column_name,column_comment,data_type,column_type 
from information_schema.columns 
where table_name=表名 and table_schema='数据库名称';