使用merge into结合分区表来合并数据,执行报错,请问Oracle是不支持这种写法吗
merge into target partition(p1) v using source s on (v.id = s.aid)
when matched then
update set v.year = s.year
when not matched then
insert values(s.aid, s.name, s.year);
ORA-14401: inserted partition key is outside specified partition
去掉partition可以执行成功,但不是我想要的
以上代码可以可以执行成功
如果是不支持,原因是什么呢?
Insert 的值不在p1分区 或者所source 中不匹配的行有部分不属于p1分区