创建数据库:CREATE DATABASE database_name;
修改表名称:ALTER TABLE ts01 RENAME to ts01_new;
创建新表:CREATE TABLE book(name char(20),author char(20));
复制旧表到新表: CREATE TABLE salaries SELECT * FROM employees;
修改列名称及类型:ALTER TABLE table_name CHANGE name1 name2 VARCHAR(30);
插入列:ALTER TABLE table_name ADD COLUMN name1 VARCHAR(30);
插入数据:INSERT INTO reader(name,author) VALUES(‘Linux’,‘Linus’);
更新数据:UPDATE table_name SET age=60 WHERE NAME=‘赵六’;
删除列:ALTER TABLE table_name DROP COLUMN name1;
删除行:DELETE FROM table_name WHERE age=18;
删除表:DROP TABLE xxx(table_name);
删除数据库:DROP DATABASE IF EXISTS database_name;
未完待续……