diff options
author | Masahiko Sawada <msawada@postgresql.org> | 2023-07-13 15:03:17 +0900 |
---|---|---|
committer | Masahiko Sawada <msawada@postgresql.org> | 2023-07-13 15:03:17 +0900 |
commit | fd48a86c6241b994ce67c8b53a918e6b42c8063c (patch) | |
tree | 13f45e1d62a0b20851773c3060079bfa96fcb268 /src/backend/executor/execReplication.c | |
parent | 0fef8775382886bef023aee67cb744711ed7a32f (diff) | |
download | postgresql-fd48a86c6241b994ce67c8b53a918e6b42c8063c.tar.gz postgresql-fd48a86c6241b994ce67c8b53a918e6b42c8063c.zip |
Doc: clarify the conditions of usable indexes for REPLICA IDENTITY FULL tables.
Commit 89e46da5e allowed REPLICA IDENTITY FULL tables to use an index
on the subscriber during apply of update/delete. This commit clarifies
in the documentation that the leftmost field of candidate indexes must
be a column (not an expression) that references the published relation
column.
The source code comments are also updated accordingly.
Reviewed-by: Peter Smith, Amit Kapila
Discussion: https://postgr.es/m/CAD21AoDJjffEvUFKXT27Q5U8-UU9JHv4rrJ9Ke8Zkc5UPWHLvA@mail.gmail.com
Backpatch-through: 16
Diffstat (limited to 'src/backend/executor/execReplication.c')
-rw-r--r-- | src/backend/executor/execReplication.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/backend/executor/execReplication.c b/src/backend/executor/execReplication.c index 9dd71684615..af093428813 100644 --- a/src/backend/executor/execReplication.c +++ b/src/backend/executor/execReplication.c @@ -47,9 +47,9 @@ static bool tuples_equal(TupleTableSlot *slot1, TupleTableSlot *slot2, * * Returns how many columns to use for the index scan. * - * This is not generic routine, it expects the idxrel to be a btree, non-partial - * and have at least one column reference (i.e. cannot consist of only - * expressions). + * This is not generic routine, idxrel must be PK, RI, or an index that can be + * used for REPLICA IDENTITY FULL table. See FindUsableIndexForReplicaIdentityFull() + * for details. * * By definition, replication identity of a rel meets all limitations associated * with that. Note that any other index could also meet these limitations. |