From: | Masahiko Sawada <sawada(dot)mshk(at)gmail(dot)com> |
---|---|
To: | torikoshia <torikoshia(at)oss(dot)nttdata(dot)com> |
Cc: | Nathan Bossart <nathandbossart(at)gmail(dot)com>, Yugo Nagata <nagata(at)sraoss(dot)co(dot)jp>, Pgsql Hackers <pgsql-hackers(at)postgresql(dot)org>, rmt(at)lists(dot)postgresql(dot)org |
Subject: | Re: Improve tab completion for COPY |
Date: | 2025-07-03 02:37:11 |
Message-ID: | CAD21AoDCPG2Zn2BscmqQ=TfsBNFokCgQP9_HNnO9zyU98yFZMg@mail.gmail.com |
Views: | Whole Thread | Raw Message | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Wed, Jul 2, 2025 at 2:46 PM torikoshia <torikoshia(at)oss(dot)nttdata(dot)com> wrote:
>
> On 2025-07-01 14:20, Masahiko Sawada wrote:
> > On Thu, Jun 12, 2025 at 3:47 AM Masahiko Sawada <sawada(dot)mshk(at)gmail(dot)com>
> > wrote:
> >>
> >> On Tue, Jun 10, 2025 at 1:33 PM Nathan Bossart
> >> <nathandbossart(at)gmail(dot)com> wrote:
> >> >
> >> > On Tue, Jun 10, 2025 at 12:37:48PM -0700, Masahiko Sawada wrote:
> >> > >> > (1) adds tab completion support for the REJECT_LIMIT option, which was
> >> > >> > introduced in v18
> >> > >> > (2) splits the tab completion logic between COPY FROM and COPY TO to
> >> > >> > reflect their different options.
> >> > >
> >> > > [...]
> >> > >
> >> > > Given REJECT_LIMIT is a new v18 feature, it seems to me that (1) is an
> >> > > oversight of this feature, but I also agree that it's not a bug and
> >> > > doesn't block the release.
> >> > >
> >> > > How does the RMT feel about the change (1)? Nathan, would you be OK with that?
> >> >
> >> > 0001 sure seems like an oversight in commit 4ac2a9b to me. In any case, I
> >> > argued that we should fix tab completion for unlogged partitioned tables in
> >> > v18 [0], and this seems pretty similar.
> >> >
> >> >
> >> > TBH I'd even say that 0002 is fixing a bug and could be back-patched. I've
> >> > added rmt@ here in case Tomas or Heikki feel differently.
> >>
> >> Thank you for your confirmation. I've just pushed the change (1) and
> >> am waiting for more comments on the change (2).
> >>
> >
> > Thinking of the 0002 patch, I'm also inclined to agree that this fixes
> > a bogus tab completion behavior for COPY command and can be
> > back-patched to v14. In v14, c273d9d8ce reworked the tab completion
> > for COPY command and supports the completion for the options of FORMAT
> > within a WITH clause so we cannot back-patch it to v13.
>
> Agreed.
>
> > Torikoshi-san, could you please prepare the patch for other branches
> > too if you agree with this direction?
>
> Sure! Attached patches.
Thank you for updating the patches! The patches mostly look good to
me. As for v3-0002-Improve-tab-completion-for-COPY-options_v17.patch,
please note that we don't support REJECT_LIMIT in v17:
+/* COPY FROM options */
+#define Copy_from_options \
+Copy_common_options, "DEFAULT", "FORCE_NOT_NULL", "FORCE_NULL", "FREEZE", \
+"LOG_VERBOSITY", "ON_ERROR", "REJECT_LIMIT"
I've attached the updated patches that addressed the above issue and
updated the commit messages. Please review them.
Regards,
--
Masahiko Sawada
Amazon Web Services: https://aws.amazon.com
Attachment | Content-Type | Size |
---|---|---|
REL16_v4-0001-Fix-tab-completion-for-COPY-and-copy-options.patch | application/octet-stream | 2.9 KB |
REL17_v4-0001-Fix-tab-completion-for-COPY-and-copy-options.patch | application/octet-stream | 3.6 KB |
REL18_v4-0001-Fix-tab-completion-for-COPY-and-copy-options.patch | application/octet-stream | 3.6 KB |
REL15_v4-0001-Fix-tab-completion-for-COPY-and-copy-options.patch | application/octet-stream | 2.8 KB |
master_v4-0001-Fix-tab-completion-for-COPY-and-copy-options.patch | application/octet-stream | 3.6 KB |
REL14_v4-0001-Fix-tab-completion-for-COPY-and-copy-options.patch | application/octet-stream | 2.8 KB |
From | Date | Subject | |
---|---|---|---|
Next Message | Amit Kapila | 2025-07-03 04:02:10 | Re: Using failover slots for PG-non_PG logical replication |
Previous Message | Michael Paquier | 2025-07-03 02:24:34 | Re: Improve verification of recovery_target_timeline GUC. |