postgres.git / summary / log / commit / refs
commit e0a537f1908f8c38c99558b1e997530874be086f
Author: Daniel Gustafsson <dgustafsson@postgresql.org>
Date: Sun Oct 25 23:18:48 2026 +0000
First released in: 14.25, 15.20, 16.16, 17.12, 18.7, 19.0
Fix tab completion for concurrent matview refresh
Refreshing materialized views with CONCURRENT cannot use WITH NO DATA,
but the tab completion supported this combination which is rejected by
the backend.
Author: Sho Ito <i.sho.0628@gmail.com>
Reviewed-by: Daniel Gustafsson <daniel@yesql.se>
Discussion: https://postgr.es/m/CAG7L5+7JOn_tjLjS1PJFTARtEybeJ1-aAAftZZ5L25_QZrjP4w@mail.gmail.com
Backpatch-through: 14
src/bin/psql/tab-complete.in.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/src/bin/psql/tab-complete.in.c b/src/bin/psql/tab-complete.in.c
index 009a659f828..a718d3e17d7 100644
--- a/src/bin/psql/tab-complete.in.c
+++ b/src/bin/psql/tab-complete.in.c
@@ -4891,10 +4891,8 @@ match_previous_words(int pattern_id,
else if (Matches("REFRESH", "MATERIALIZED", "VIEW", MatchAny, "WITH"))
COMPLETE_WITH("NO DATA", "DATA");
else if (Matches("REFRESH", "MATERIALIZED", "VIEW", "CONCURRENTLY", MatchAny, "WITH"))
- COMPLETE_WITH("NO DATA", "DATA");
- else if (Matches("REFRESH", "MATERIALIZED", "VIEW", MatchAny, "WITH", "NO"))
COMPLETE_WITH("DATA");
- else if (Matches("REFRESH", "MATERIALIZED", "VIEW", "CONCURRENTLY", MatchAny, "WITH", "NO"))
+ else if (Matches("REFRESH", "MATERIALIZED", "VIEW", MatchAny, "WITH", "NO"))
COMPLETE_WITH("DATA");
/* REINDEX */
[parent: b9662d4be6c7]