merge into new n using emp e
on(n.empno=e.empno)
when matched then update set n.sal=e.sal
when not matched then
insert (n.empno,n.ename,n.sal,n.comm)
values(e.empno,e.ename,e.sal,e.comm);
on(n.empno=e.empno)
when matched then update set n.sal=e.sal
when not matched then
insert (n.empno,n.ename,n.sal,n.comm)
values(e.empno,e.ename,e.sal,e.comm);
来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/30090120/viewspace-1422795/,如需转载,请注明出处,否则将追究法律责任。
转载于:http://blog.itpub.net/30090120/viewspace-1422795/