查询某个表的字段名字及信息
方法1:desc <table_name>
例子:查看表名字:GreyList
方法2:show create table <table_name>
例子:查看GreyList表show create table GreyList;
方法3:SELECT * FROM information_schema.columnsWHERE table_schema = <your_database_name> AND table_name = <your_table_name>
例子:查看GreyList表
SELECT * FROM information_schema.columnsWHERE table_schema = ‘nebulalib’ AND table_name = ‘GreyList’;
备注:不要忘记mysql语句后面加 ‘;’ 结束语句