日期:2014-05-16 浏览次数:20941 次
create table tj_test(id number,name varchar2(20),age number); insert into tj_test values (1,'jan',23); insert into tj_test values (2,'kk',22); insert into tj_test values (3,'joe',27); create table tj_test1 as select * from tj_test where 1=0; insert into tj_test1 values (1,'jlk',23); merge into tj_test1 tt1 using tj_test tt on (tt1.id=tt.id) when matched then update set tt1.name=tt.name, tt1.age=tt.age when not matched then insert values(tt.id, tt.name, tt.age);
------解决方案--------------------
那你就先把Excel导入临时表。然后merge into