# 数据库的创建、删除和使用createdatabase[name];dropdatabase[name];use[name];# 表的创建、打印、修改与删除createtable player (id INT,name VARCHAR(100),levelINT,exp INT,gold DECIMAL(10,2))DESC player;ALTERTABLE player MODIFYlevelINTDEFAULT1;# 设置默认值ALTERTABLE player MODIFYCOLUMN name VARCHAR(200);# 修改表头类型ALTERTABLE player RENAMECOLUMN name to NickName;# 表头重命名ALTERTABLE player ADDCOLUMN LastLogin DATETIME;# 添加行ALTERTABLE player DROPCOLUMN LastLogin;# 删除行DROPTABLE player;# 数据的增删改查INSERTINTO player (id, name,level, exp, gold)VALUES(001,'dyang',1,1,0);SELECT*FROM player;UPDATE player SETlevel=1while name ='a';DELETEFROM player gold =0;