标签:sel tar into var 逗号 姓名 innodb work mysq
1.创建一个表:
主键id | 用户名 | 性别 | 体重(kg) | 生日 | 工资 | 上次登陆时间 | 个人简介 |
CREATE TABLE homework(
id INT(10) NOT NULL PRIMARY KEY
)ENGINE=INNODB DEFAULT CHARSET=utf8;
ALTER TABLE homework ADD NAME VARCHAR(20)
ALTER TABLE homework ADD sex CHAR(1) AFTER NAME;
ALTER TABLE homework ADD number INT(2) FIRST;
ALTER TABLE homework DROP number;
DESC homework;
ALTER TABLE homework MODIFY weight DECIMAL(3,2);
ALTER TABLE homework CHANGE jianjie jieshao VARCHAR(30);
INSERT INTO homework(id,NAME) VALUES(11,‘小明‘);
INSERT INTO homework VALUES(77,‘小画‘,‘女‘,55.366,19990826,12233.346,SYSDATE(),‘经理‘);
DELETE FROM homework WHERE sex=‘女‘ AND jieshao=‘经理‘;
标签:sel tar into var 逗号 姓名 innodb work mysq
原文地址:http://www.cnblogs.com/oat0/p/6188058.html