CREATE CLUSTER EMP_DEPT_CLUSTER(DEPTNO NUMBER(2))
PCTUSED 80
PCTFREE 15
SIZE 1024
TABLESPACE USERS
create index emp_dept_cluster_idx on cluster emp_dept_cluster;
CREATE TABLE CL_DEPT(
DEPTNO NUMBER(2) PRIMARY KEY,
DNAME VARCHAR2(14),
LOC VARCHAR2(13)
)
cluster emp_dept_cluster(deptno)
CREATE TABLE CL_EMP
(
EMPNO NUMBER PRIMARY KEY,
ENAME VARCHAR2(10),
JOB VARCHAR2(10),
MGR NUMBER,
HIREDATE DATE,
SAL NUMBER,
COMM NUMBER,
DEPTNO NUMBER(2) REFERENCES CL_DEPT(DEPTNO)
)
CLUSTER EMP_DEPT_CLUSTER ( DEPTNO);
沒有留言:
張貼留言