mysql怎么获取表中属性值

mysql获取表属性值的方法
1.查询数据表中所有字段的属性
select * from information_schema.columns
where table_schema= '数据库库名' and table_name = '表名'
2.查询数据库中所有字段的属性
select * from information_schema.columns
where table_schema= '数据库库名'
3.查询数据库中特定列条件字段的属性
select table_schema,table_name,column_name,column_type,column_comment
from information_schema.columns
where TABLE_SCHEMA='数据库名' and column_name = '字段名';
声明:本站所有作品(图文、音视频)均由用户自行上传分享,或互联网相关知识整合,仅供网友学习交流,若您的权利被侵害,请联系 管理员 删除。
本文链接:http://news.ew35.com/
