. 서브쿼리로 테이블 생성하기
create table emp_01
AS
select * from emp;
(권한은 복사되지 않는다. 그냥 값만 복사한 것)
create table emp_02
as
select * from emp where deptno = 30;
select table emp_03
as
select ename, dname, loc,sal from emp, dept
where emp.deptno = dept.deptno
and emp.deptno = 30;
create table emp_04
as
select ename, sal, hiredate from emp where sal > 1500;
create table emp_05
as
select * from emp where 1 = 0;
(성립안되는 것만 적어주면 틀만 복사된다.)