oracle体系结构
oracle体系结构: Oracle server大体分为两部分:instance和database database包括:Data files,Control files,Redo Log files instance包括:SGA(内存块):主要包括5个:Shared Pool(Library Cache,Data Dictionary Cache),DB Buffer Cache,JavaPool, Redo Log Buffer,Large Pool 后台进程:PMON,SMON,DBWR,LGWR,CKPT,Others 还包括其他的一些文件如:Parameter file,Password file,Archived Log files oracle 内存结构包括两个内存区:SGA(System Global Area)和PGA(Program
分区表
分区的方法:按范围分区(如时间,)分到各个表空间的blocksize应该一样一、range partitioningcreate table saless(acct_no number(2),person varchar2(2),week_no number(2))partition by range(week_no)(partition p1 values less than (4) tablespace data0,partition p2 values less than (8) tablespace data1,....partition p13 values less than (53) tablespace data12,);查找:select * from table1 partition(p1) select * from table1 partition(p2) ---超出分区范围则报错,修改为:alter table range1 add pa
集群表
一、index cluster1、create cluster mycluster (deptno number(2)) size 1024; ---deptno:列名,1024,1个8K的block能放8k/1024字节 (8)条记录 ---不算头文件共7条,如果不设置的话,默认是1条,如果 是 小表的话会很浪费。2、create index myc_idx on cluster mycluster;--3、 create table deptt(deptid number(2) primary key, dname varchar2(3)) cluster mycluster(deptid);4、 create table empp(empid number primary key, ename varchar2(3), deptno number(2) references dept(deptid) ) cluster myc