Re: Use RELATION_IS_OTHER_TEMP where possible - Mailing list pgsql-hackers

From Ashutosh Bapat
Subject Re: Use RELATION_IS_OTHER_TEMP where possible
Date
Msg-id CAExHW5v+eWp0dVg4e-_d9-7Z4HSQYKK6iZ5JsFeHyBK-WGHE_w@mail.gmail.com
Whole thread Raw
In response to Re: Use RELATION_IS_OTHER_TEMP where possible  (Junwang Zhao <zhjwpku@gmail.com>)
Responses Re: Use RELATION_IS_OTHER_TEMP where possible
List pgsql-hackers


On Wed, Jun 11, 2025 at 5:12 AM Junwang Zhao <zhjwpku@gmail.com> wrote:
Hi Nathan,

On Wed, Jun 11, 2025 at 12:30 AM Nathan Bossart
<nathandbossart@gmail.com> wrote:
>
> On Wed, Jun 11, 2025 at 12:07:35AM +0800, Junwang Zhao wrote:
> > All other files perform this check using RELATION_IS_OTHER_TEMP.
> > Should we update tablecmds.c to do the same for consistency?
>
> Seems like a good idea.

Thanks for the comment.

I have attached a patch with the proposed changes.

LGTM. I looked at other instances of is_localtemp, but none of them have (relation)->rd_rel->relpersistence == RELPERSISTENCE_TEMP there. Your patch has covered all the existing ones. 

--
Best Wishes,
Ashutosh Bapat

pgsql-hackers by date:

Previous
From: shveta malik
Date:
Subject: Re: Question on error code selection in conflict detection
Next
From: "David G. Johnston"
Date:
Subject: Re: Possibly hard-to-read message