修改约束
alter table t add primary key (c);
alter table t add unique (c);
alter table t add foreign key (c) references t2(c2);
alter table t alter c set default val;
alter table t drop primary key;
alter table t drop unique (c);
alter table t drop foreign key fkname;
alter table t drop index (c);
alter table t add primary key (c);
alter table t add unique (c);
alter table t add foreign key (c) references t2(c2);
alter table t alter c set default val;
alter table t drop primary key;
alter table t drop unique (c);
alter table t drop foreign key fkname;
alter table t drop index (c);
CREATE TABLE tbname (字段 属性);
SHOW COLUMNS FROM tbname;
INSERT [INTO] tbname( 字段)VALUES(属性值);
INSERT [INTO] tbname VALUES(所有属性值);
SHOW COLUMNS FROM tbname;
INSERT [INTO] tbname( 字段)VALUES(属性值);
INSERT [INTO] tbname VALUES(所有属性值);
2018-10-27