]> granicus.if.org Git - postgresql/commitdiff
Document the DEFERRABLE option in SET TRANSACTION command.
authorHeikki Linnakangas <heikki.linnakangas@iki.fi>
Mon, 7 Mar 2011 08:42:49 +0000 (10:42 +0200)
committerHeikki Linnakangas <heikki.linnakangas@iki.fi>
Mon, 7 Mar 2011 08:43:41 +0000 (10:43 +0200)
Kevin Grittner

doc/src/sgml/ref/set_transaction.sgml

index 2c57f45511b3d6a1ce563b691c1dec697f518742..f864bbf6a61c35000928f0ea83b255be464f7e23 100644 (file)
@@ -135,6 +135,17 @@ SET SESSION CHARACTERISTICS AS TRANSACTION <replaceable class="parameter">transa
    among those listed.  This is a high-level notion of read-only that
    does not prevent all writes to disk.
   </para>
+
+  <para>
+   The <literal>DEFERRABLE</literal> transaction property has no effect
+   unless the transaction is also <literal>SERIALIZABLE</literal> and
+   <literal>READ ONLY</literal>.  When all of these properties are set on a
+   transaction, the transaction may block when first acquiring its snapshot,
+   after which it is able to run without the normal overhead of a
+   <literal>SERIALIZABLE</literal> transaction and without any risk of
+   contributing to or being cancelled by a serialization failure.  This mode
+   is well suited for long-running reports or backups.
+  </para>
  </refsect1>
 
  <refsect1>