Skip to content

Commit e611539

Browse files
nathan-bossartÁlvaro Herrera
andcommitted
Document pg_get_multixact_members().
Oversight in commit 0ac5ad5. Author: Sami Imseih <samimseih@gmail.com> Co-authored-by: Álvaro Herrera <alvherre@kurilemu.de> Reviewed-by: Ashutosh Bapat <ashutosh.bapat.oss@gmail.com> Discussion: https://postgr.es/m/20150619215231.GT133018%40postgresql.org Discussion: https://postgr.es/m/CAA5RZ0sjQDDwJfMRb%3DZ13nDLuRpF13ME2L_BdGxi0op8RKjmDg%40mail.gmail.com Backpatch-through: 13
1 parent 7a7b3e1 commit e611539

File tree

2 files changed

+31
-2
lines changed

2 files changed

+31
-2
lines changed

doc/src/sgml/func.sgml

Lines changed: 27 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27704,6 +27704,31 @@ acl | {postgres=arwdDxtm/postgres,foo=r/postgres}
2770427704
details.
2770527705
</para></entry>
2770627706
</row>
27707+
27708+
<row>
27709+
<entry role="func_table_entry"><para role="func_signature">
27710+
<indexterm>
27711+
<primary>pg_get_multixact_members</primary>
27712+
</indexterm>
27713+
<function>pg_get_multixact_members</function> ( <parameter>multixid</parameter> <type>xid</type> )
27714+
<returnvalue>setof record</returnvalue>
27715+
( <parameter>xid</parameter> <type>xid</type>,
27716+
<parameter>mode</parameter> <type>text</type> )
27717+
</para>
27718+
<para>
27719+
Returns the transaction ID and lock mode for each member of the
27720+
specified multixact ID. The lock modes <literal>forupd</literal>,
27721+
<literal>fornokeyupd</literal>, <literal>sh</literal>, and
27722+
<literal>keysh</literal> correspond to the row-level locks
27723+
<literal>FOR UPDATE</literal>, <literal>FOR NO KEY UPDATE</literal>,
27724+
<literal>FOR SHARE</literal>, and <literal>FOR KEY SHARE</literal>,
27725+
respectively, as described in <xref linkend="locking-rows"/>. Two
27726+
additional modes are specific to multixacts:
27727+
<literal>nokeyupd</literal>, used by updates that do not modify key
27728+
columns, and <literal>upd</literal>, used by updates or deletes that
27729+
modify key columns.
27730+
</para></entry>
27731+
</row>
2770727732
</tbody>
2770827733
</tgroup>
2770927734
</table>
@@ -27712,7 +27737,8 @@ acl | {postgres=arwdDxtm/postgres,foo=r/postgres}
2771227737
The internal transaction ID type <type>xid</type> is 32 bits wide and
2771327738
wraps around every 4 billion transactions. However,
2771427739
the functions shown in <xref linkend="functions-pg-snapshot"/>, except
27715-
<function>age</function> and <function>mxid_age</function>, use a
27740+
<function>age</function>, <function>mxid_age</function>, and
27741+
<function>pg_get_multixact_members</function>, use a
2771627742
64-bit type <type>xid8</type> that does not wrap around during the life
2771727743
of an installation and can be converted to <type>xid</type> by casting if
2771827744
required; see <xref linkend="transaction-id"/> for details.

doc/src/sgml/maintenance.sgml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -779,7 +779,10 @@ HINT: Execute a database-wide VACUUM in that database.
779779
careful aging management, storage cleanup, and wraparound handling.
780780
There is a separate storage area which holds the list of members in
781781
each multixact, which also uses a 32-bit counter and which must also
782-
be managed.
782+
be managed. The system function
783+
<function>pg_get_multixact_members()</function> described in
784+
<xref linkend="functions-pg-snapshot"/> can be used to examine the
785+
transaction IDs associated with a multixact ID.
783786
</para>
784787

785788
<para>

0 commit comments

Comments
 (0)