Thread
-
Re: [PATCH] Fix column name escaping in postgres_fdw stats import
Ayush Tiwari <ayushtiwari.slg01@gmail.com> — 2026-05-03T22:23:53Z
Hi Fujita-san, On Tue, 21 Apr, 2026, 18:39 Etsuro Fujita, <etsuro.fujita@gmail.com> wrote: > > No, you shouldn't, but I think it's usual to discuss (essentially) the > same problem in a single place. Are there some edits you would like me to make on the patch? Or would you like me to add the thread link to open items for 19? Regards, Ayush
-
Re: [PATCH] Fix column name escaping in postgres_fdw stats import
Etsuro Fujita <etsuro.fujita@gmail.com> — 2026-05-12T07:36:12Z
Hi Ayush, On Mon, May 4, 2026 at 7:24 AM Ayush Tiwari <ayushtiwari.slg01@gmail.com> wrote: > Are there some edits you would like me to make on the patch? One thing I noticed is the test case you added; it only tests departing column names with single quotes, but it's better to also test that with backslashes, to confirm the patch addresses the issue in [1] as well. So I updated the patch as such. New version attached. Other than that the patch looks good to me, so I'll push it if no objections from you (or anyone else). > Or would you like me to add the thread link to open items for 19? I added this thread to an existing open item as the second report. Sorry for the delay. Best regards, Etsuro Fujita [1] https://www.postgresql.org/message-id/CAHg%2BQDc9%3DWtYi%3DJW6QUL6ASOJc6PcGPTuxoMkhnkQ7oi7j5atg%40mail.gmail.com
-
Re: [PATCH] Fix column name escaping in postgres_fdw stats import
Ayush Tiwari <ayushtiwari.slg01@gmail.com> — 2026-05-12T08:02:44Z
Hi Fujita-san, On Tue, 12 May 2026 at 13:06, Etsuro Fujita <etsuro.fujita@gmail.com> wrote: > Hi Ayush, > > On Mon, May 4, 2026 at 7:24 AM Ayush Tiwari <ayushtiwari.slg01@gmail.com> > wrote: > > Are there some edits you would like me to make on the patch? > > One thing I noticed is the test case you added; it only tests > departing column names with single quotes, but it's better to also > test that with backslashes, to confirm the patch addresses the issue > in [1] as well. So I updated the patch as such. New version > attached. Other than that the patch looks good to me, so I'll push it > if no objections from you (or anyone else). > > Thanks for the updated version, and for folding in the backslash case from [1]. I confirmed that the patch applies cleanly on master and that make -C contrib/postgres_fdw check passes, including the new dtest_ftable case. The merged test seems a strict improvement. No objections from me. Regards, Ayush
-
Re: [PATCH] Fix column name escaping in postgres_fdw stats import
Zhenwei Shang <a934172442@gmail.com> — 2026-05-13T07:27:24Z
Ayush Tiwari <ayushtiwari.slg01@gmail.com> 于2026年5月12日周二 16:03写道: > Hi Fujita-san, > > On Tue, 12 May 2026 at 13:06, Etsuro Fujita <etsuro.fujita@gmail.com> > wrote: > >> Hi Ayush, >> >> On Mon, May 4, 2026 at 7:24 AM Ayush Tiwari <ayushtiwari.slg01@gmail.com> >> wrote: >> > Are there some edits you would like me to make on the patch? >> >> One thing I noticed is the test case you added; it only tests >> departing column names with single quotes, but it's better to also >> test that with backslashes, to confirm the patch addresses the issue >> in [1] as well. So I updated the patch as such. New version >> attached. Other than that the patch looks good to me, so I'll push it >> if no objections from you (or anyone else). >> >> > Thanks for the updated version, and for folding in the backslash case > from [1]. > > I confirmed that the patch applies cleanly on master and that > make -C contrib/postgres_fdw check passes, including the new > dtest_ftable case. The merged test seems a strict improvement. > > No objections from me. > > Regards, > Ayush > The patch overall looks solid to me. A tiny suggestion, while here, would it make sense to also add comma and brace column names to the test, as they are classic array-literal hazards, like “col,comma” and “col{brace”? Regards, Zhenwei Shang -
Re: [PATCH] Fix column name escaping in postgres_fdw stats import
Etsuro Fujita <etsuro.fujita@gmail.com> — 2026-05-13T11:22:16Z
Hi, On Wed, May 13, 2026 at 4:27 PM Zhenwei Shang <a934172442@gmail.com> wrote: > Ayush Tiwari <ayushtiwari.slg01@gmail.com> 于2026年5月12日周二 16:03写道: >> On Tue, 12 May 2026 at 13:06, Etsuro Fujita <etsuro.fujita@gmail.com> wrote: >>> One thing I noticed is the test case you added; it only tests >>> departing column names with single quotes, but it's better to also >>> test that with backslashes, to confirm the patch addresses the issue >>> in [1] as well. So I updated the patch as such. New version >>> attached. Other than that the patch looks good to me, so I'll push it >>> if no objections from you (or anyone else). >> Thanks for the updated version, and for folding in the backslash case >> from [1]. >> >> I confirmed that the patch applies cleanly on master and that >> make -C contrib/postgres_fdw check passes, including the new >> dtest_ftable case. The merged test seems a strict improvement. >> >> No objections from me. Cool! Thanks for double-checking, Ayush! > The patch overall looks solid to me. A tiny suggestion, while here, would it make sense to also add comma and brace column names to the test, as they are classic array-literal hazards, like “col,comma” and “col{brace”? Those cases are handled correctly even without the patch, so sorry, I don't feel the need to extend the test further. Anyway, thanks for reviewing, Zhenwei! Best regards, Etsuro Fujita -
Re: [PATCH] Fix column name escaping in postgres_fdw stats import
Etsuro Fujita <etsuro.fujita@gmail.com> — 2026-05-14T08:47:17Z
On Wed, May 13, 2026 at 8:22 PM Etsuro Fujita <etsuro.fujita@gmail.com> wrote: > On Wed, May 13, 2026 at 4:27 PM Zhenwei Shang <a934172442@gmail.com> wrote: > > The patch overall looks solid to me. A tiny suggestion, while here, would it make sense to also add comma and brace column names to the test, as they are classic array-literal hazards, like “col,comma” and “col{brace”? > Those cases are handled correctly even without the patch, so sorry, I > don't feel the need to extend the test further. Pushed. I didn't extend the test, but I think we could do so later if needed. I closed the entry in the PG20-1 CF as well as the open item. Best regards, Etsuro Fujita