navicat 快速导出表结构
SELECT
COLUMN_NAME 列名,
COLUMN_TYPE 数据类型,
IS_NULLABLE 是否允许空值,
COLUMN_COMMENT 注释,
COLUMN_KEY 主键
FROM
information_schema.`COLUMNS`
WHERE
TABLE_SCHEMA='xxx' -- TABLE_SCHEMA是数据库名
AND
table_name='xxx' -- table_name是表名
转载自https://blog.csdn.net/weixin_42440768/article/details/109365091?utm_medium=distribute.pc_relevant.none-task-blog-2defaultbaidujs_title~default-0.showsourcetag&spm=1001.2101.3001.4242.1