create table 表名(
字段名 类型 约束,
字段名 类型 约束
...
)
create table students(
name varchar(10)
)
create table students(
name varchar(10),
age int unsigned
)
create table students(
id int unsigned primary key auto_increment,
name varchar(20),
age int unsigned,
height decimal(5,2)
)
格式⼀:drop table 表名
格式⼆:drop table if exists 表名
drop table students
或
drop table if exists students
欢迎光临 黑马程序员技术交流社区 (http://bbs.itheima.com/) | 黑马程序员IT技术论坛 X3.2 |