From d99d58cdc8c0b5b50ee92995e8575c100b1a458a Mon Sep 17 00:00:00 2001 From: Alvaro Herrera Date: Sat, 13 May 2017 01:05:48 -0300 Subject: Complete tab completion for DROP STATISTICS Tab-completing DROP STATISTICS would only work if you started writing the schema name containing the statistics object, because the visibility clause was missing. To add it, we need to add SQL-callable support for testing visibility of a statistics object, like all other object types already have. Discussion: https://postgr.es/m/22676.1494557205@sss.pgh.pa.us --- src/bin/psql/tab-complete.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/bin/psql/tab-complete.c') diff --git a/src/bin/psql/tab-complete.c b/src/bin/psql/tab-complete.c index 09fb30f270c..ae3730257d1 100644 --- a/src/bin/psql/tab-complete.c +++ b/src/bin/psql/tab-complete.c @@ -622,7 +622,7 @@ static const SchemaQuery Query_for_list_of_statistics = { /* selcondition */ NULL, /* viscondition */ - NULL, + "pg_catalog.pg_statistic_ext_is_visible(s.oid)", /* namespace */ "s.stxnamespace", /* result */ -- cgit v1.2.3