mirror of
https://github.com/postgres/postgres.git
synced 2025-07-15 19:21:59 +03:00
Prevent psql tab completion in SET from adding TO when the equals sign
has no space before it. Report by Erik Rijkers
This commit is contained in:
@ -2842,6 +2842,7 @@ psql_completion(char *text, int start, int end)
|
|||||||
pg_strcasecmp(prev_wd, "TABLESPACE") != 0 &&
|
pg_strcasecmp(prev_wd, "TABLESPACE") != 0 &&
|
||||||
pg_strcasecmp(prev_wd, "SCHEMA") != 0 &&
|
pg_strcasecmp(prev_wd, "SCHEMA") != 0 &&
|
||||||
prev_wd[strlen(prev_wd) - 1] != ')' &&
|
prev_wd[strlen(prev_wd) - 1] != ')' &&
|
||||||
|
prev_wd[strlen(prev_wd) - 1] != '=' &&
|
||||||
pg_strcasecmp(prev4_wd, "DOMAIN") != 0)
|
pg_strcasecmp(prev4_wd, "DOMAIN") != 0)
|
||||||
COMPLETE_WITH_CONST("TO");
|
COMPLETE_WITH_CONST("TO");
|
||||||
/* Suggest possible variable values */
|
/* Suggest possible variable values */
|
||||||
|
Reference in New Issue
Block a user