From: | "shiy(dot)fnst(at)fujitsu(dot)com" <shiy(dot)fnst(at)fujitsu(dot)com> |
---|---|
To: | Peter Smith <smithpb2250(at)gmail(dot)com> |
Cc: | Kyotaro Horiguchi <horikyota(dot)ntt(at)gmail(dot)com>, "pgsql-hackers(at)lists(dot)postgresql(dot)org" <pgsql-hackers(at)lists(dot)postgresql(dot)org> |
Subject: | RE: Fix some newly modified tab-complete changes |
Date: | 2022-10-10 06:12:09 |
Message-ID: | OSZPR01MB63107AD7499FE2139B245375FD209@OSZPR01MB6310.jpnprd01.prod.outlook.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Tue, Oct 4, 2022 4:17 PM Peter Smith <smithpb2250(at)gmail(dot)com> wrote:
>
> On Thu, Sep 29, 2022 at 12:50 PM shiy(dot)fnst(at)fujitsu(dot)com
> <shiy(dot)fnst(at)fujitsu(dot)com> wrote:
> >
> > On Wed, Sep 28, 2022 1:49 PM Kyotaro Horiguchi
> <horikyota(dot)ntt(at)gmail(dot)com> wrote:
> > >
> > > At Wed, 28 Sep 2022 14:14:01 +1000, Peter Smith
> > > <smithpb2250(at)gmail(dot)com> wrote in
> ...
> > > >
> > > > 2. tab complete for GRANT
> > > >
> > > > test_pub=# grant <tab>
> > > > ALL EXECUTE
> > > > pg_execute_server_program pg_read_server_files postgres
> > > > TRIGGER
> > > > ALTER SYSTEM GRANT pg_monitor
> > > > pg_signal_backend REFERENCES
> > > > TRUNCATE
> > > > CONNECT INSERT pg_read_all_data
> > > > pg_stat_scan_tables SELECT UPDATE
> > > > CREATE pg_checkpoint
> > > > pg_read_all_settings pg_write_all_data SET
> > > > USAGE
> > > > DELETE pg_database_owner
> > > > pg_read_all_stats pg_write_server_files TEMPORARY
> > > >
> > > > 2a.
> > > > grant "GRANT" ??
> > >
> > > Yeah, for the mement I thought that might a kind of admin option but
> > > there's no such a privilege. REVOKE gets the same suggestion.
> > >
> >
> > Maybe that's for "REVOKE GRANT OPTION FOR". But it is used by both
> GRANT and
> > REVOKE. I think it's a separate problem, I have tried to fix it in the attached
> > 0002 patch.
> >
>
> I checked your v2-0002 patch and AFAICT it does fix properly the
> previously reported GRANT/REVOKE problem.
>
Thanks for reviewing and testing it.
> ~
>
> But, while testing I noticed another different quirk
>
> It seems that neither the GRANT nor the REVOKE auto-complete
> recognises the optional PRIVILEGE keyword
>
> e.g. GRANT ALL <tab> --> ON (but not PRIVILEGE)
> e.g. GRANT ALL PRIV<tab> --> ???
>
> e.g. REVOKE ALL <tab> --> ON (but not PRIVILEGE)..
> e.g. REVOKE ALL PRIV<tab> --> ???
>
I tried to add tab-completion for it. Pleases see attached updated patch.
Regards,
Shi yu
Attachment | Content-Type | Size |
---|---|---|
v3-0001-Fix-tab-completion-for-GRANT-REVOKE.patch | application/octet-stream | 7.9 KB |
From | Date | Subject | |
---|---|---|---|
Next Message | Peter Eisentraut | 2022-10-10 06:24:43 | Re: list of acknowledgments for PG15 |
Previous Message | Bharath Rupireddy | 2022-10-10 06:03:57 | Re: Switching XLog source from archive to streaming when primary available |