Add text to the VACUUM, REINDEX, DROP TABLESPACE and CREATE TABLESPACE
authorNeil Conway
Tue, 31 Oct 2006 01:52:31 +0000 (01:52 +0000)
committerNeil Conway
Tue, 31 Oct 2006 01:52:31 +0000 (01:52 +0000)
reference pages documenting that these commands cannot be used within
a transaction block. Also make some minor improvements to the psql
reference page. Patch from Simon Riggs, minor editorialization by
myself.

doc/src/sgml/ref/cluster.sgml
doc/src/sgml/ref/create_tablespace.sgml
doc/src/sgml/ref/drop_tablespace.sgml
doc/src/sgml/ref/psql-ref.sgml
doc/src/sgml/ref/reindex.sgml
doc/src/sgml/ref/vacuum.sgml

index f72c7ac00676102cd25a6c57eab8aec0d02343e6..17c185e076026ca879f52545da80992f2461feb6 100644 (file)
@@ -1,5 +1,5 @@
 
 
@@ -60,8 +60,8 @@ CLUSTER
    in the
    current database that the calling user owns, or all tables if called
    by a superuser.  (Never-clustered tables are not included.)  This
-   form of CLUSTER cannot be called from inside a
-   transaction or function.
+   form of CLUSTER cannot be executed inside a transaction
+   block.
   
 
   
index 8f64dbe2c8e9799f2d8e55ed89f9d7a8864a8c01..797591d613a8b8920f018aa3aa844311a9452ef8 100644 (file)
@@ -1,5 +1,5 @@
 
 
@@ -95,6 +95,11 @@ CREATE TABLESPACE tablespacename [
   
    Tablespaces are only supported on systems that support symbolic links.
   
+
+   
+    CREATE TABLESPACE cannot be executed inside a transaction
+    block.
+   
  
 
  
index 080aa478eba92b03119c1303a53fe7dcae7b4748..25772eadd3139abb1489008994a04e8ddc1f78e4 100644 (file)
@@ -1,5 +1,5 @@
 
 
@@ -66,6 +66,15 @@ DROP TABLESPACE [ IF EXISTS ] tablespacename
   
  
 
+  Notes
+
+   
+    DROP TABLESPACE cannot be executed inside a transaction block.
+   
+
+
  
   Examples
 
index d80249c7daefe250815c561e5a5e811c9a2f361e..be04f63284b540ff8f17cc03371efa7a0ed1c99e 100644 (file)
@@ -1,5 +1,5 @@
 
 
@@ -94,9 +94,10 @@ PostgreSQL documentation
       
        If the command string contains multiple SQL commands, they are
        processed in a single transaction, unless there are explicit
-       BEGIN/COMMIT commands included in the string to divide it into
-       multiple transactions.  This is different from the behavior when
-       the same string is fed to psql's standard input.
+       BEGIN/COMMIT commands included in the
+       string to divide it into multiple transactions.  This is
+       different from the behavior when the same string is fed to
+       psql's standard input.
       
       
     
@@ -472,9 +473,14 @@ PostgreSQL documentation
         
         BEGIN/COMMIT around the script to execute it
         as a single transaction.  This ensures that either all the commands
-        complete successfully, or no changes are applied.  (However, if the
-        script itself uses BEGIN or COMMIT, this
-        option will not have the desired effect!)
+        complete successfully, or no changes are applied.  
+       
+
+       
+        If the script itself uses BEGIN, COMMIT
+        or any command that cannot be executed inside a transaction
+        block, specifying this option will cause the transaction to be
+        aborted.
        
       
      
index 574b8effd1c68933e7d8cbc280ecf2208300846d..661a219adc2a08655b5dde46333e5fb1087a275f 100644 (file)
@@ -1,5 +1,5 @@
 
 
@@ -106,7 +106,8 @@ REINDEX { INDEX | TABLE | DATABASE | SYSTEM } nam
      
       Recreate all indexes within the current database.
       Indexes on shared system catalogs are skipped except in stand-alone mode
-      (see below).
+      (see below). This form of REINDEX cannot be executed 
+      inside a transaction block.
      
     
    
@@ -118,6 +119,8 @@ REINDEX { INDEX | TABLE | DATABASE | SYSTEM } nam
       Recreate all indexes on system catalogs within the current database.
       Indexes on user tables are not processed.  Also, indexes on shared
       system catalogs are skipped except in stand-alone mode (see below).
+      This form of REINDEX cannot be executed inside a
+      transaction block.
      
     
    
index 225590a5cd26262c733d14fa46a7e2a17451d025..0764aa6807972d12aba1d8cdc1c6ecd57fd6c2f2 100644 (file)
@@ -1,5 +1,5 @@
 
 
@@ -155,6 +155,10 @@ VACUUM [ FULL | FREEZE ] [ VERBOSE ] ANALYZE [ ta
  
   Notes
 
+   
+    VACUUM cannot be executed inside a transaction block.
+   
+
    
     We recommend that active production databases be
     vacuumed frequently (at least nightly), in order to