Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 96c498d

Browse filesBrowse files
author
Amit Kapila
committed
Add tab-completion for newly added SUBSCRIPTION options.
Commits c3afe8c and 4826759 added new subscription options "password_required" and "run_as_owner". This patch adds tab-completion for these newly added options. Author: Peter Smith Discussion: https://postgr.es/m/CAHut+Pu=pnJf=SS1583pknSQ3CbOqLCkWcJCQYt6zxTagHEdmw@mail.gmail.com
1 parent 8fcb32d commit 96c498d
Copy full SHA for 96c498d

File tree

1 file changed

+4
-2
lines changed
Filter options

1 file changed

+4
-2
lines changed

‎src/bin/psql/tab-complete.c

Copy file name to clipboardExpand all lines: src/bin/psql/tab-complete.c
+4-2Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1925,7 +1925,8 @@ psql_completion(const char *text, int start, int end)
19251925
COMPLETE_WITH("(", "PUBLICATION");
19261926
/* ALTER SUBSCRIPTION <name> SET ( */
19271927
else if (HeadMatches("ALTER", "SUBSCRIPTION", MatchAny) && TailMatches("SET", "("))
1928-
COMPLETE_WITH("binary", "disable_on_error", "origin", "slot_name",
1928+
COMPLETE_WITH("binary", "disable_on_error", "origin",
1929+
"password_required", "run_as_owner", "slot_name",
19291930
"streaming", "synchronous_commit");
19301931
/* ALTER SUBSCRIPTION <name> SKIP ( */
19311932
else if (HeadMatches("ALTER", "SUBSCRIPTION", MatchAny) && TailMatches("SKIP", "("))
@@ -3268,7 +3269,8 @@ psql_completion(const char *text, int start, int end)
32683269
/* Complete "CREATE SUBSCRIPTION <name> ... WITH ( <opt>" */
32693270
else if (HeadMatches("CREATE", "SUBSCRIPTION") && TailMatches("WITH", "("))
32703271
COMPLETE_WITH("binary", "connect", "copy_data", "create_slot",
3271-
"disable_on_error", "enabled", "origin", "slot_name",
3272+
"disable_on_error", "enabled", "origin",
3273+
"password_required", "run_as_owner", "slot_name",
32723274
"streaming", "synchronous_commit", "two_phase");
32733275

32743276
/* CREATE TRIGGER --- is allowed inside CREATE SCHEMA, so use TailMatches */

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.