select * from tb_test;
insert into tb_test(CODE, TEXT) values (1, 'test');
 
-- 这里正常
merge into tb_test t
using (select 1 code,'test' text from dual union all
       select 1 code,'test' text from dual) s
on (t.code = s.code)
when matched then
update set t.text = s.text;
 
-- 这里 error: ORA-30926
merge into tb_test t
using (select 1 code,'test1' text from dual union all
       select 1 code,'test1' text from dual) s
on (t.code = s.code)
when matched then
update set t.text = s.text;
 
-- 这里 error: ORA-30926
merge into tb_test t
using (select 1 code,'test1' text from dual union all
       select 1 code,'test2' text from dual) s
on (t.code = s.code)
when matched then
update set t.text = s.text;
已有0条评论