Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit5024044

Browse files
committed
C comments: improve description of relfilenode uniqueness
Report by Antonin Houska
1 parent11d205e commit5024044

File tree

3 files changed

+6
-5
lines changed

3 files changed

+6
-5
lines changed

‎src/backend/catalog/catalog.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -408,8 +408,8 @@ GetNewOidWithIndex(Relation relation, Oid indexId, AttrNumber oidcolumn)
408408

409409
/*
410410
* GetNewRelFileNode
411-
*Generate a new relfilenode number that is unique within the given
412-
*tablespace.
411+
*Generate a new relfilenode number that is unique within the
412+
*database of the giventablespace.
413413
*
414414
* If the relfilenode will also be used as the relation's OID, pass the
415415
* opened pg_class catalog, and this routine will guarantee that the result

‎src/backend/commands/tablecmds.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9078,8 +9078,8 @@ ATExecSetTableSpace(Oid tableOid, Oid newTableSpace, LOCKMODE lockmode)
90789078
FlushRelationBuffers(rel);
90799079

90809080
/*
9081-
* Relfilenodes are not unique across tablespaces, so we need to allocate
9082-
* a new one in the new tablespace.
9081+
* Relfilenodes are not uniquein databasesacross tablespaces, so we
9082+
*need to allocatea new one in the new tablespace.
90839083
*/
90849084
newrelfilenode=GetNewRelFileNode(newTableSpace,NULL,
90859085
rel->rd_rel->relpersistence);

‎src/include/storage/relfilenode.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,8 @@ typedef enum ForkNumber
5555
* relNode identifies the specific relation. relNode corresponds to
5656
* pg_class.relfilenode (NOT pg_class.oid, because we need to be able
5757
* to assign new physical files to relations in some situations).
58-
* Notice that relNode is only unique within a particular tablespace.
58+
* Notice that relNode is only unique within a database in a particular
59+
* tablespace.
5960
*
6061
* Note: spcNode must be GLOBALTABLESPACE_OID if and only if dbNode is
6162
* zero. We support shared relations only in the "global" tablespace.

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp