ExecAggTransReparent is underdocumented and badly named

Started by Tom Lanealmost 3 years ago1 messageshackers
Jump to latest
#1Tom Lane
tgl@sss.pgh.pa.us

I wondered at [1]/messages/by-id/2199319.1681662388@sss.pgh.pa.us why ExecAggTransReparent doesn't do what you'd
guess from the name, that is reparent a supplied R/W expanded object
under the aggcontext even if it's not there already. I tried to
make it do that, and after I'd finished bandaging my wounds,
I wrote some commentary explaining why that won't work. (Possibly
we knew this at some point, but if so we sure failed to provide
documentation about it.)

I think we should at least apply the attached commentary-only
patch. I wonder though if we should change the name of this
function, and if so to what. Maybe ExecAggCopyTransValue?

regards, tom lane

[1]: /messages/by-id/2199319.1681662388@sss.pgh.pa.us

Attachments:

document-ExecAggTransReparent-better.patchtext/x-diff; charset=us-ascii; name=document-ExecAggTransReparent-better.patchDownload+23-6