Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit e6c4e01

Browse files
committed
Review wording on tablespaces w.r.t. partitioned tables
Remove a redundant comment, and document pg_class.reltablespace properly in catalogs.sgml. After commits a36c84c, 8725958 and others. Backpatch to 12. Discussion: https://postgr.es/m/202403191013.w2kr7wqlamqz@alvherre.pgsql
1 parent 1f4eb73 commit e6c4e01

File tree

2 files changed

+6
-7
lines changed

2 files changed

+6
-7
lines changed

doc/src/sgml/catalogs.sgml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2010,9 +2010,12 @@ SCRAM-SHA-256$<replaceable>&lt;iteration count&gt;</replaceable>:<replaceable>&l
20102010
(references <link linkend="catalog-pg-tablespace"><structname>pg_tablespace</structname></link>.<structfield>oid</structfield>)
20112011
</para>
20122012
<para>
2013-
The tablespace in which this relation is stored. If zero,
2014-
the database's default tablespace is implied. (Not meaningful
2015-
if the relation has no on-disk file.)
2013+
The tablespace in which this relation is stored.
2014+
If zero, the database's default tablespace is implied.
2015+
Not meaningful if the relation has no on-disk file,
2016+
except for partitioned tables, where this is the tablespace
2017+
in which partitions will be created when one is not
2018+
specified in the creation command.
20162019
</para></entry>
20172020
</row>
20182021

src/backend/commands/tablecmds.c

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -785,10 +785,6 @@ DefineRelation(CreateStmt *stmt, char relkind, Oid ownerId,
785785
}
786786
else if (stmt->partbound)
787787
{
788-
/*
789-
* For partitions, when no other tablespace is specified, we default
790-
* the tablespace to the parent partitioned table's.
791-
*/
792788
Assert(list_length(inheritOids) == 1);
793789
tablespaceId = get_rel_tablespace(linitial_oid(inheritOids));
794790
}

0 commit comments

Comments
 (0)