支持TYPE…IS RECORD语句
CREATE TABLE emp(
empno number(4) not null,
ename varchar2(10),
job varchar2(9),
mgr number(4),
hiredate date,
sal number(7,2),
comm number(7,2),
deptno number(2)
);
INSERT INTO emp VALUES (7369,’SMITH’,’CLERK’,7902,TO_DATE(’17-DEC-1980’,’DD-MON-YYYY’),800,NULL,20);
INSERT INTO emp VALUES (7499,’ALLEN’,’SALESMAN’,7698,TO_DATE(’20-FEB-1981’,’DD-MON-YYYY’),1600,300,30);
INSERT INTO emp VALUES (7521,’WARD’,’SALESMAN’,7698,TO_DATE(’22-FEB-1981’,’DD-MON-YYYY’),1250,500,30);
CREATE TABLE dept(
deptno number(2),
dname varchar2(14),
loc varchar2(13)
);
INSERT INTO dept VALUES (10,'ACCOUNTING','NEW YORK');
INSERT INTO dept VALUES (20,'RESEARCH','DALLAS');
INSERT INTO dept VALUES (30,'SALES','CHICAGO');
INSERT INTO dept VALUES (40,'OPERATIONS','BOSTON');