Mysql 查看表结构的命令

创建数据库
create database abc;

显示数据库

show databases;

使用数据库

use 数据库名;

直接打开数据库

mysql -h localhost -u root -p123456 -d 数据库名

显示表

show tables;

desc 表名;
show columns from 表名;
describe 表名;
show create table 表名;
use information_schema
select * from columns where table_name='表名';

原文地址:https://www.cnblogs.com/mouseleo/p/8541880.html