/*创建表 不带自动标示*/
create table product
(
pid number(15) primary key not null,
pname varchar2(20) not null
);
commit;
insert into product(pid,pname) values(1,'美瞳');
commit;
/*清楚表记录*/
truncate table product;
commit;
select * from Product;
/*查看表结构*/
desc product
drop table orders;
/*创建表 带自动标示*/
create table orders
(
oid number(15) primary key not null,
pname varchar2(50) not null
);
create sequence oid_id start with 001001 cache 2;/*创建自动标示序列*/
insert into orders(oid,pname) values(oid_id.nextval,'美瞳'); commit;