oracle学习64-oracle之数据处理之其他数据库对象

 

 

 

--创建序列
create sequence empseq
increment by 10---每次增长10
start with 10--从10开始
maxvalue 100--提供最大值
cycle --循环
nocache --不需要缓存登录

 

 

--创建表
create table emp11
as
select employee_id,last_name,salary
from employees
where 1=2
 
--插入表
insert into emp11
values(empseq.nextval,'BB',1000)
 
--查询
select * from emp11

 

--修改
alter sequence empseq
increment by 1---每次增长10
--start with 10--从10开始
--maxvalue 100--提供最大值
nocycle --循环
nocache --

 

 

 

 

 

 

--手动创建索引
create index emp11_index
on emp11(employee_id)

 

posted @ 2022-08-13 21:30  前端导师歌谣  阅读(23)  评论(0)    收藏  举报