-
Notifications
You must be signed in to change notification settings - Fork 883
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix handling of oldtuple to match PG17 upstream #7340
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #7340 +/- ##
==========================================
+ Coverage 80.06% 82.58% +2.51%
==========================================
Files 190 229 +39
Lines 37181 42728 +5547
Branches 9450 10734 +1284
==========================================
+ Hits 29770 35285 +5515
- Misses 2997 3164 +167
+ Partials 4414 4279 -135 ☔ View full report in Codecov by Sentry. |
#if PG17_GE | ||
if (oldtuple != NULL) | ||
ExecForceStoreHeapTuple(oldtuple, resultRelInfo->ri_oldTupleSlot, | ||
false); | ||
else | ||
#endif |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like this code in upstream was added by this commit postgres/postgres@5f2e179 so I think there are more things to import, no?
Also what this new code is fixing cause seems our regression tests are not reaching it per codecov?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I was having a close look on it and actually we need to introduce support for MERGE ... WHEN NOT MATCHED BY SOURCE THEN ...
for hypertables instead and it will require more work on ht_hypertable_modify.c
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this is mostly to silence coverity
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like the coverity was already silenced, no? I mean it will no hurt to merge this tiny PR but it still requires more work to sync it with upstream. I'm working on another PR to make this new merge clause work for hypertables because I want to use it on the new cagg refresh code using merge statement.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A previous commit I made added support for MERGE ... RETURNING ...
.
While working on the coverity fix, I realized that this code handling oldtuple
was not added; that's what this fixes.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@kpan2034 would be good then mention it on the commit message and in the PR description to make clear the change you're proposing.
30231d3
to
09ff3e3
Compare
A previous commit I made added support for MERGE ... RETURNING ....
While working on the coverity fix, I realized that this code handling oldtuple was not added; that's what this fixes.
Disable-check: force-changelog-file