--创建表格
create table test (name varchar2(8), age number(4), job varchar(8) ) ----------------------------------------------------------------------------------------------------------------------------- --修改表格
alter table test --增加一列 add(hiredate date) alter table test --修改数据类型 modify(hiredate varchar(10)) select *from test alter table test -- 删除一列 drop(age) ------------------------------------------------------------------------------------------------------------------------------- --插入数据 insert into test (name,job,hiredate)values ('0000','哈哈','05-01-1998'); insert into test (name,job,hiredate)values ('0001','哈哈1','05-01-1998'); insert into test (name,job,hiredate)values ('0002','哈哈2','05-01-1998'); insert into test (name,job,hiredate)values ('0003','哈哈3','05-01-1998'); insert into test (name,job,hiredate)values ('0004','哈哈4','05-01-1998'); delete test where name='0000'--删除数据 ------------------------------------------------------------------------------------------------------------------------------- --更新数据
update test set name='姓名' where name like '%00%' select *from test truncate table test -- 清空表内数据
--
drop table test --删除表
执行完之后,表将不复存在,只能再次创建新表