Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit c168c88

Browse files
committed
Don't tab-complete COMMENT ON ... IS with IS.
Ian Barwick
1 parent 72dd233 commit c168c88

File tree

1 file changed

+7
-6
lines changed

1 file changed

+7
-6
lines changed

src/bin/psql/tab-complete.c

+7-6
Original file line numberDiff line numberDiff line change
@@ -2130,12 +2130,13 @@ psql_completion(const char *text, int start, int end)
21302130
{
21312131
COMPLETE_WITH_QUERY(Query_for_list_of_event_triggers);
21322132
}
2133-
else if ((pg_strcasecmp(prev4_wd, "COMMENT") == 0 &&
2134-
pg_strcasecmp(prev3_wd, "ON") == 0) ||
2135-
(pg_strcasecmp(prev5_wd, "COMMENT") == 0 &&
2136-
pg_strcasecmp(prev4_wd, "ON") == 0) ||
2137-
(pg_strcasecmp(prev6_wd, "COMMENT") == 0 &&
2138-
pg_strcasecmp(prev5_wd, "ON") == 0))
2133+
else if (((pg_strcasecmp(prev4_wd, "COMMENT") == 0 &&
2134+
pg_strcasecmp(prev3_wd, "ON") == 0) ||
2135+
(pg_strcasecmp(prev5_wd, "COMMENT") == 0 &&
2136+
pg_strcasecmp(prev4_wd, "ON") == 0) ||
2137+
(pg_strcasecmp(prev6_wd, "COMMENT") == 0 &&
2138+
pg_strcasecmp(prev5_wd, "ON") == 0)) &&
2139+
pg_strcasecmp(prev_wd, "IS") != 0)
21392140
COMPLETE_WITH_CONST("IS");
21402141

21412142
/* COPY */

0 commit comments

Comments
 (0)