Re: Tab completion for CREATE SCHEMAAUTHORIZATION
Michael Paquier <michael@paquier.xyz>
From: Michael Paquier <michael@paquier.xyz>
To: Dagfinn Ilmari Mannsåker <ilmari@ilmari.org>
Cc: Suraj Khamkar <khamkarsuraj.b@gmail.com>, pgsql-hackers@lists.postgresql.org
Date: 2023-05-02T02:09:59Z
Lists: pgsql-hackers
On Sat, Apr 15, 2023 at 11:06:25AM +0900, Michael Paquier wrote:
> Thanks, I'll look at it.
+ else if (Matches("CREATE", "SCHEMA", "AUTHORIZATION", MatchAny) ||
+ Matches("CREATE", "SCHEMA", MatchAny, "AUTHORIZATION", MatchAny))
+ COMPLETE_WITH("CREATE", "GRANT");
+ else if (Matches("CREATE", "SCHEMA", MatchAny))
+ COMPLETE_WITH("AUTHORIZATION", "CREATE", "GRANT");
I had this grammar under my eyes a few days ago for a different patch,
and there are much more objects types that can be appended to a CREATE
SCHEMA, like triggers, sequences, tables or views, so this is
incomplete, isn't it?
--
Michael
Commits
-
Add tab completion for CREATE SCHEMA in psql
- c951e9042dd1 17.0 landed
-
psql: improve tab-complete's handling of variant SQL names.
- 02b8048ba5dc 15.0 cited