Commit 095d4012 authored by Robert Haas's avatar Robert Haas

Tab complete second argument to \c with role names.

Ian Barwick
parent 67067f9a
...@@ -3704,6 +3704,8 @@ psql_completion(const char *text, int start, int end) ...@@ -3704,6 +3704,8 @@ psql_completion(const char *text, int start, int end)
} }
else if (strcmp(prev_wd, "\\connect") == 0 || strcmp(prev_wd, "\\c") == 0) else if (strcmp(prev_wd, "\\connect") == 0 || strcmp(prev_wd, "\\c") == 0)
COMPLETE_WITH_QUERY(Query_for_list_of_databases); COMPLETE_WITH_QUERY(Query_for_list_of_databases);
else if (strcmp(prev2_wd, "\\connect") == 0 || strcmp(prev2_wd, "\\c") == 0)
COMPLETE_WITH_QUERY(Query_for_list_of_roles);
else if (strncmp(prev_wd, "\\da", strlen("\\da")) == 0) else if (strncmp(prev_wd, "\\da", strlen("\\da")) == 0)
COMPLETE_WITH_SCHEMA_QUERY(Query_for_list_of_aggregates, NULL); COMPLETE_WITH_SCHEMA_QUERY(Query_for_list_of_aggregates, NULL);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment