Tab complete second argument to \c with role names.

Ian Barwick
This commit is contained in:
Robert Haas 2014-11-10 08:15:17 -05:00
parent 67067f9ae3
commit 095d40123c
1 changed files with 2 additions and 0 deletions

View File

@ -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)
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)
COMPLETE_WITH_SCHEMA_QUERY(Query_for_list_of_aggregates, NULL);