From ecd222e770d352121590363ffdf981147a43e976 Mon Sep 17 00:00:00 2001 From: Fujii Masao Date: Fri, 15 May 2015 20:09:57 +0900 Subject: Support VERBOSE option in REINDEX command. When this option is specified, a progress report is printed as each index is reindexed. Per discussion, we agreed on the following syntax for the extensibility of the options. REINDEX (flexible options) { INDEX | ... } name Sawada Masahiko. Reviewed by Robert Haas, Fabrízio Mello, Alvaro Herrera, Kyotaro Horiguchi, Jim Nasby and me. Discussion: CAD21AoA0pK3YcOZAFzMae+2fcc3oGp5zoRggDyMNg5zoaWDhdQ@mail.gmail.com --- src/test/regress/expected/create_index.out | 8 ++++++++ src/test/regress/sql/create_index.sql | 8 ++++++++ 2 files changed, 16 insertions(+) (limited to 'src/test') diff --git a/src/test/regress/expected/create_index.out b/src/test/regress/expected/create_index.out index abe64e597c7..a98b10520d5 100644 --- a/src/test/regress/expected/create_index.out +++ b/src/test/regress/expected/create_index.out @@ -2831,6 +2831,14 @@ explain (costs off) Index Cond: ((thousand = 1) AND (tenthous = 1001)) (2 rows) +-- +-- REINDEX (VERBOSE) +-- +CREATE TABLE reindex_verbose(id integer primary key); +\set VERBOSITY terse +REINDEX (VERBOSE) TABLE reindex_verbose; +INFO: index "reindex_verbose_pkey" was reindexed +DROP TABLE reindex_verbose; -- -- REINDEX SCHEMA -- diff --git a/src/test/regress/sql/create_index.sql b/src/test/regress/sql/create_index.sql index f779fa0de17..6333a30bf6d 100644 --- a/src/test/regress/sql/create_index.sql +++ b/src/test/regress/sql/create_index.sql @@ -965,6 +965,14 @@ RESET enable_indexscan; explain (costs off) select * from tenk1 where (thousand, tenthous) in ((1,1001), (null,null)); +-- +-- REINDEX (VERBOSE) +-- +CREATE TABLE reindex_verbose(id integer primary key); +\set VERBOSITY terse +REINDEX (VERBOSE) TABLE reindex_verbose; +DROP TABLE reindex_verbose; + -- -- REINDEX SCHEMA -- -- cgit v1.2.3