oracle中with as 的用法

版权声明:本文为博主原创文章,遵循 CC 4.0 by-sa 版权协议,转载请附上原文出处链接和本声明。
本文链接:https://blog.csdn.net/ruiguang21/article/details/80693697
select * from emp;
select * from empinfo;
truncate table empinfo
insert into empinfo
(
empno,
ename,
job,
mgr,
HIREDATE
)
with temp_ as
(
select empno,ename,job,mgr from emp
),
 temp as (  
     select * from emp  
)  
select 
t.empno,
t.ename,
t.job,
t.mgr,
tp.HIREDATE
from temp_ t,temp tp where t.empno=tp.empno;  
展开阅读全文

没有更多推荐了,返回首页