aboutsummaryrefslogtreecommitdiff
path: root/doc/src
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2014-07-23 15:20:31 -0400
committerTom Lane <tgl@sss.pgh.pa.us>2014-07-23 15:20:31 -0400
commit4fd9e6ffdd9aae51a935c255cbf7691c369ded1b (patch)
treee2fc4ea8fda581d1a55310ceb1869b2631d5a671 /doc/src
parent0ea1f2a3a8dfcbe8062a65a13700fc5ae83482c6 (diff)
downloadpostgresql-4fd9e6ffdd9aae51a935c255cbf7691c369ded1b.tar.gz
postgresql-4fd9e6ffdd9aae51a935c255cbf7691c369ded1b.zip
Rearrange documentation paragraph describing pg_relation_size().
Break the list of available options into an <itemizedlist> instead of inline sentences. This is mostly motivated by wanting to ensure that the cross-references to the FSM and VM docs don't cross page boundaries in PDF format; but it seems to me to read more easily this way anyway. I took the liberty of editorializing a bit further while at it. Per complaint from Magnus about 9.0.18 docs not building in A4 format. Patch all active branches so we don't get blind-sided by this particular issue again in future.
Diffstat (limited to 'doc/src')
-rw-r--r--doc/src/sgml/func.sgml48
1 files changed, 34 insertions, 14 deletions
diff --git a/doc/src/sgml/func.sgml b/doc/src/sgml/func.sgml
index bf131403b0b..19c2d6cab6c 100644
--- a/doc/src/sgml/func.sgml
+++ b/doc/src/sgml/func.sgml
@@ -16928,20 +16928,40 @@ postgres=# SELECT * FROM pg_xlogfile_name_offset(pg_stop_backup());
</para>
<para>
- <function>pg_relation_size</> accepts the OID or name of a table, index or
- toast table, and returns the on-disk size in bytes.
- Specifying <literal>'main'</literal> or leaving out the second argument
- returns the size of the main data fork of the relation.
- Specifying <literal>'fsm'</literal> returns the size of the Free Space
- Map (see <xref linkend="storage-fsm">) associated with the relation.
- Specifying <literal>'vm'</literal> returns the size of the Visibility
- Map (see <xref linkend="storage-vm">) associated with the relation.
- Specifying <literal>'init'</literal> returns the size of the
- initialization fork, if any, associated with the relation.
- Note that this function shows the size of only one fork;
- for most purposes it is more convenient to use the higher-level
- functions <function>pg_total_relation_size</> or
- <function>pg_table_size</>.
+ <function>pg_relation_size</> accepts the OID or name of a table, index
+ or toast table, and returns the on-disk size in bytes of one fork of
+ that relation. (Note that for most purposes it is more convenient to
+ use the higher-level functions <function>pg_total_relation_size</>
+ or <function>pg_table_size</>, which sum the sizes of all forks.)
+ With one argument, it returns the size of the main data fork of the
+ relation. The second argument can be provided to specify which fork
+ to examine:
+ <itemizedlist spacing="compact">
+ <listitem>
+ <para>
+ <literal>'main'</literal> returns the size of the main
+ data fork of the relation.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+ <literal>'fsm'</literal> returns the size of the Free Space Map
+ (see <xref linkend="storage-fsm">) associated with the relation.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+ <literal>'vm'</literal> returns the size of the Visibility Map
+ (see <xref linkend="storage-vm">) associated with the relation.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+ <literal>'init'</literal> returns the size of the initialization
+ fork, if any, associated with the relation.
+ </para>
+ </listitem>
+ </itemizedlist>
</para>
<para>