Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'src/bin/psql')
-rw-r--r--src/bin/psql/common.c4
-rw-r--r--src/bin/psql/mainloop.c14
-rw-r--r--src/bin/psql/tab-complete.c11
3 files changed, 16 insertions, 13 deletions
diff --git a/src/bin/psql/common.c b/src/bin/psql/common.c
index 2b1c4daceda..b56995925bd 100644
--- a/src/bin/psql/common.c
+++ b/src/bin/psql/common.c
@@ -2047,8 +2047,8 @@ command_no_begin(const char *query)
/*
* Commands not allowed within transactions. The statements checked for
- * here should be exactly those that call PreventInTransactionBlock() in the
- * backend.
+ * here should be exactly those that call PreventInTransactionBlock() in
+ * the backend.
*/
if (wordlen == 6 && pg_strncasecmp(query, "vacuum", 6) == 0)
return true;
diff --git a/src/bin/psql/mainloop.c b/src/bin/psql/mainloop.c
index c06ce3ca09c..6caca2e575c 100644
--- a/src/bin/psql/mainloop.c
+++ b/src/bin/psql/mainloop.c
@@ -247,9 +247,8 @@ MainLoop(FILE *source)
/*
* If we found a command word, check whether the rest of the line
* contains only whitespace plus maybe one semicolon. If not,
- * ignore the command word after all. These commands are only
- * for compatibility with other SQL clients and are not
- * documented.
+ * ignore the command word after all. These commands are only for
+ * compatibility with other SQL clients and are not documented.
*/
if (rest_of_line != NULL)
{
@@ -330,18 +329,17 @@ MainLoop(FILE *source)
}
/*
- * If they typed "\q" in a place where "\q" is not active,
- * supply a hint. The text is still added to the query
- * buffer.
+ * If they typed "\q" in a place where "\q" is not active, supply
+ * a hint. The text is still added to the query buffer.
*/
if (found_q && query_buf->len != 0 &&
prompt_status != PROMPT_READY &&
prompt_status != PROMPT_CONTINUE &&
prompt_status != PROMPT_PAREN)
#ifndef WIN32
- puts(_("Use control-D to quit."));
+ puts(_("Use control-D to quit."));
#else
- puts(_("Use control-C to quit."));
+ puts(_("Use control-C to quit."));
#endif
}
diff --git a/src/bin/psql/tab-complete.c b/src/bin/psql/tab-complete.c
index 264728212f6..b431efc9832 100644
--- a/src/bin/psql/tab-complete.c
+++ b/src/bin/psql/tab-complete.c
@@ -1856,13 +1856,13 @@ psql_completion(const char *text, int start, int end)
/* ALTER INDEX <foo> SET|RESET ( */
else if (Matches5("ALTER", "INDEX", MatchAny, "RESET", "("))
COMPLETE_WITH_LIST7("fillfactor", "recheck_on_update",
- "fastupdate", "gin_pending_list_limit", /* GIN */
+ "fastupdate", "gin_pending_list_limit", /* GIN */
"buffering", /* GiST */
"pages_per_range", "autosummarize" /* BRIN */
);
else if (Matches5("ALTER", "INDEX", MatchAny, "SET", "("))
COMPLETE_WITH_LIST7("fillfactor =", "recheck_on_update =",
- "fastupdate =", "gin_pending_list_limit =", /* GIN */
+ "fastupdate =", "gin_pending_list_limit =", /* GIN */
"buffering =", /* GiST */
"pages_per_range =", "autosummarize =" /* BRIN */
);
@@ -2511,6 +2511,7 @@ psql_completion(const char *text, int start, int end)
COMPLETE_WITH_SCHEMA_QUERY(Query_for_list_of_indexes,
" UNION SELECT 'ON'"
" UNION SELECT 'CONCURRENTLY'");
+
/*
* Complete ... INDEX|CONCURRENTLY [<name>] ON with a list of relations
* that can indexes can be created on
@@ -3458,7 +3459,11 @@ psql_completion(const char *text, int start, int end)
/* Complete SET <var> with "TO" */
else if (Matches2("SET", MatchAny))
COMPLETE_WITH_CONST("TO");
- /* Complete ALTER DATABASE|FUNCTION||PROCEDURE|ROLE|ROUTINE|USER ... SET <name> */
+
+ /*
+ * Complete ALTER DATABASE|FUNCTION||PROCEDURE|ROLE|ROUTINE|USER ... SET
+ * <name>
+ */
else if (HeadMatches2("ALTER", "DATABASE|FUNCTION|PROCEDURE|ROLE|ROUTINE|USER") &&
TailMatches2("SET", MatchAny))
COMPLETE_WITH_LIST2("FROM CURRENT", "TO");