Bruce Momjian <pgman@candle.pha.pa.us> writes:
> Yep, I think everything now points to changes needed in relcache.c to
> handle the new condition of a relation swapping its relnode.
I still don't believe that any changes are needed in relcache.c.
In particular, after thinking more I see that we do not need to change
the myxactonly status of either relation: the temp one is still temp,
the original one is still not.
What we do need to do is to flush all buffers for the two rels from the
local and global buffer caches respectively, since after the swap they
should get buffered in different places. FlushRelationBuffers looks
like it will work for that.
regards, tom lane