!1091 修复包含全局唯一索引的分区表执行upsert时数据未正常写入的问题

Merge pull request !1091 from siven/siven_07
This commit is contained in:
opengauss-bot
2021-07-22 11:28:59 +00:00
committed by Gitee

View File

@ -1304,7 +1304,7 @@ bool ExecCheckIndexConstraints(TupleTableSlot* slot, EState* estate,
ereport(ERROR, (errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
errmsg("INSERT ON DUPLICATE KEY UPDATE does not support deferrable"
" unique constraints/exclusion constraints.")));
if (isPartitioned) {
if (isPartitioned && !RelationIsGlobalIndex(indexRelation)) {
partitionedindexid = RelationGetRelid(indexRelation);
if (!PointerIsValid(partitionIndexOidList)) {
partitionIndexOidList = PartitionGetPartIndexList(p);