Commit 2a972e01 authored by Heikki Linnakangas's avatar Heikki Linnakangas

Fix TRUNCATE doc: ALTER SEQUENCE RESTART is now transactional.

ALTER SEQUENCE RESTART was made transactional in commit 3d79013b.
Backpatch to v10, where that was introduced.

Patch by Justin Pryzby, per Yaroslav Schekin's report.

Discussion: https://www.postgresql.org/message-id/20201005191922.GE17626%40telsasoft.com
parent c0bc4c68
......@@ -160,8 +160,7 @@ TRUNCATE [ TABLE ] [ ONLY ] <replaceable class="parameter">name</replaceable> [
When <literal>RESTART IDENTITY</literal> is specified, the implied
<command>ALTER SEQUENCE RESTART</command> operations are also done
transactionally; that is, they will be rolled back if the surrounding
transaction does not commit. This is unlike the normal behavior of
<command>ALTER SEQUENCE RESTART</command>. Be aware that if any additional
transaction does not commit. Be aware that if any additional
sequence operations are done on the restarted sequences before the
transaction rolls back, the effects of these operations on the sequences
will be rolled back, but not their effects on <function>currval()</function>;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment