Thanks for helping with this. On Wed, Aug 12, 2020 at 01:54:38PM +0900, Michael Paquier wrote: > +++ b/src/backend/catalog/index.c > @@ -3661,20 +3662,12 @@ reindex_relation(Oid relid, int flags, int options) > + elog(ERROR, "unsupported relation kind for relation \"%s\"", > + RelationGetRelationName(rel));
I guess it should show the relkind(%c) in the message, like these: src/backend/commands/tablecmds.c: elog(ERROR, "unexpected relkind: %d", (int) relkind); src/backend/tcop/utility.c: elog(ERROR, "unexpected relkind \"%c\" on partition \"%s\"", ISTM reindex_index is missing that, too: 8b08f7d4820fd7a8ef6152a9dd8c6e3cb01e5f99 + if (iRel->rd_rel->relkind == RELKIND_PARTITIONED_INDEX) + elog(ERROR, "unsupported relation kind for index \"%s\"", + RelationGetRelationName(iRel)); > diff --git a/doc/src/sgml/ref/reindex.sgml b/doc/src/sgml/ref/reindex.sgml > @@ -259,8 +263,12 @@ REINDEX [ ( <replaceable > class="parameter">option</replaceable> [, ...] ) ] { IN > </para> > > <para> > - Reindexing partitioned tables or partitioned indexes is not supported. > - Each individual partition can be reindexed separately instead. > + Reindexing partitioned indexes or partitioned tables is supported > + with respectively <command>REINDEX INDEX</command> or > + <command>REINDEX TABLE</command>. Should say "..with REINDEX INDEX or REINDEX TABLE, respectively". > + Each partition of the partitioned > + relation defined is rebuilt in its own transaction. => Each partition of the specified partitioned relation is reindexed in a separate transaction. -- Justin