--查看当前用户的所有表
select table_name from user_tables;
--查看当前用户的所有视图
select view_name from user_views;
--查看当前用户的所有约束条件
select constraint_name from user_constraints;
================================================================
索引(indexs)和视图(views)
建立索引
create index idx_stu_email on stu (email);
删除索引
drop index idx_stu_email;
查看索引
select index_name from user_indexes
访问量大(优化性能)才建索引,不要轻易建立索引;
视图
create view v$_stu as select id, name, age from stu;
=================================================================
sequence_and_review
oracle特有的 序列(sequence)
create table article
(
id number,
title varchar2(1024),
cont long
);
创建序列
create sequence seq;
插入使用序列
insert into article values (seq.nextval,'a','b');