mirror of
https://github.com/postgres/postgres.git
synced 2025-06-16 06:01:02 +03:00
doc: Update ALTER SEQUENCE claims about changes being nontransactional
Clarify that all changes except RESTART are transactional (since
1753b1b027
).
Reported-by: Michael Paquier <michael.paquier@gmail.com>
This commit is contained in:
@ -180,6 +180,14 @@ ALTER SEQUENCE [ IF EXISTS ] <replaceable class="parameter">name</replaceable> S
|
|||||||
the start value that was recorded by <command>CREATE SEQUENCE</>
|
the start value that was recorded by <command>CREATE SEQUENCE</>
|
||||||
or last set by <command>ALTER SEQUENCE START WITH</>.
|
or last set by <command>ALTER SEQUENCE START WITH</>.
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
|
<para>
|
||||||
|
Like a <function>setval</function> call, a <literal>RESTART</literal>
|
||||||
|
operation on a sequence is never rolled back, to avoid blocking of
|
||||||
|
concurrent transactions that obtain numbers from the same sequence.
|
||||||
|
(The other clauses cause ordinary catalog updates that can be rolled
|
||||||
|
back.)
|
||||||
|
</para>
|
||||||
</listitem>
|
</listitem>
|
||||||
</varlistentry>
|
</varlistentry>
|
||||||
|
|
||||||
@ -281,15 +289,6 @@ ALTER SEQUENCE [ IF EXISTS ] <replaceable class="parameter">name</replaceable> S
|
|||||||
<refsect1>
|
<refsect1>
|
||||||
<title>Notes</title>
|
<title>Notes</title>
|
||||||
|
|
||||||
<para>
|
|
||||||
To avoid blocking of concurrent transactions that obtain numbers from the
|
|
||||||
same sequence, <command>ALTER SEQUENCE</command>'s effects on the sequence
|
|
||||||
generation parameters are never rolled back; those changes take effect
|
|
||||||
immediately and are not reversible. However, the <literal>OWNED BY</>,
|
|
||||||
<literal>OWNER TO</>, <literal>RENAME TO</>, and <literal>SET SCHEMA</>
|
|
||||||
clauses cause ordinary catalog updates that can be rolled back.
|
|
||||||
</para>
|
|
||||||
|
|
||||||
<para>
|
<para>
|
||||||
<command>ALTER SEQUENCE</command> will not immediately affect
|
<command>ALTER SEQUENCE</command> will not immediately affect
|
||||||
<function>nextval</> results in backends,
|
<function>nextval</> results in backends,
|
||||||
|
Reference in New Issue
Block a user