Fix obsolete references to old-style contrib installation methods.
authorTom Lane
Mon, 14 Feb 2011 06:10:44 +0000 (01:10 -0500)
committerTom Lane
Mon, 14 Feb 2011 06:10:44 +0000 (01:10 -0500)
doc/src/sgml/contrib-spi.sgml
doc/src/sgml/contrib.sgml
doc/src/sgml/dict-int.sgml
doc/src/sgml/dict-xsyn.sgml
doc/src/sgml/earthdistance.sgml
doc/src/sgml/hstore.sgml
doc/src/sgml/pgstatstatements.sgml
doc/src/sgml/tablefunc.sgml
doc/src/sgml/test-parser.sgml
doc/src/sgml/tsearch2.sgml
doc/src/sgml/unaccent.sgml

index 85980f6e551b8a0bec521bf2737d00c3372708c7..55e5ce264925f60ef6ab7f9db4eec9facf79cdf0 100644 (file)
   below) while creating a trigger.
  
 
+  Each of the groups of functions described below is provided as a
+  separately-installable extension.
+
  
-  refint<span class="marked">.c</span> — Functions for Implementing Referential Integrity
+  refint — Functions for Implementing Referential Integrity
 
   
    check_primary_key() and
@@ -59,7 +64,7 @@
  
 
  
-  timetravel<span class="marked">.c</span> — Functions for Implementing Time Travel
+  timetravel — Functions for Implementing Time Travel
 
   
    Long ago, PostgreSQL had a built-in time travel feature
@@ -152,7 +157,7 @@ CREATE TABLE mytab (
  
 
  
-  autoinc<span class="marked">.c</span> — Functions for Autoincrementing Fields
+  autoinc — Functions for Autoincrementing Fields
 
   
    autoinc() is a trigger that stores the next value of
@@ -179,7 +184,7 @@ CREATE TABLE mytab (
  
 
  
-  insert_username<span class="marked">.c</span> — Functions for Tracking Who Changed a Table
+  insert_username — Functions for Tracking Who Changed a Table
 
   
    insert_username() is a trigger that stores the current
@@ -200,7 +205,7 @@ CREATE TABLE mytab (
  
 
  
-  moddatetime<span class="marked">.c</span> — Functions for Tracking Last Modification Time
+  moddatetime — Functions for Tracking Last Modification Time
 
   
    moddatetime() is a trigger that stores the current
index 75d08d5f6954472066ee14f99cd6faab7f677fcf..4504ab1749d08346a0ce97a93d935a61f9bb7f9f 100644 (file)
  
   Many modules supply new user-defined functions, operators, or types.
   To make use of one of these modules, after you have installed the code
-  you need to register the new objects in the database
-  system by running the SQL commands in the .sql file
-  supplied by the module.  For example,
+  you need to register the new SQL objects in the database system.
+  In PostgreSQL 9.1 and later, this is done by executing
+  a  command.  In a fresh database,
+  you can simply do
 
 
-psql -d dbname -f SHAREDIR/contrib/module.sql
+CREATE EXTENSION module_name;
 
 
-  Here, SHAREDIR means the installation's share
-  directory (pg_config --sharedir will tell you what this is).
-  In most cases the script must be run by a database superuser.
-
-  You need to run the .sql file in each database that you want
+  This command must be run by a database superuser.  This registers the
+  new SQL objects in the current database only, so you need to run this
+  command in each database that you want
   the module's facilities to be available in.  Alternatively, run it in
-  database template1 so that the module will be copied into
+  database template1 so that the extension will be copied into
   subsequently-created databases by default.
  
 
  
-  You can modify the first command in the .sql file to determine
-  which schema within the database the module's objects will be created in.
-  By default, they will be placed in public.
+  Many modules allow you to install their objects in a schema of your
+  choice.  To do that, add SCHEMA
+  schema_name to the CREATE EXTENSION
+  command.  By default, the objects will be placed in your current creation
+  target schema, typically public.
  
 
  
-  After a major-version upgrade of PostgreSQL, run the
-  installation script again, even though the module's objects might have
-  been brought forward from the old installation by dump and restore.
-  This ensures that any new functions will be available and any needed
-  corrections will be applied.
+  If your database was brought forward by dump and reload from a pre-9.1
+  version of PostgreSQL, and you had been using the pre-9.1
+  version of the module in it, you should instead do
+
+
+CREATE EXTENSION module_name FROM unpackaged;
+
+
+  This will update the pre-9.1 objects of the module into a proper
+  extension object.  Future updates to the module will be
+  managed by .
+  For more information about extension updates, see
+  .
  
 
  &adminpack;
index b1d69e1a4c8abe0715db6b16541f6c1669fce05a..17f98c05fa7862f3390e062c022f849fc15d55e3 100644 (file)
@@ -47,8 +47,8 @@
   Usage
 
   
-   Running the installation script creates a text search template
-   intdict_template and a dictionary intdict
+   Installing the dict_int extension creates a text search
+   template intdict_template and a dictionary intdict
    based on it, with the default parameters.  You can alter the
    parameters, for example
 
index e77889e388ece60333ad292a761677c78a3672b8..23c5d983c1f3d7263090dce42628f520b52921e0 100644 (file)
@@ -87,8 +87,8 @@ word syn1 syn2 syn3
   Usage
 
   
-   Running the installation script creates a text search template
-   xsyn_template and a dictionary xsyn
+   Installing the dict_xsyn extension creates a text search
+   template xsyn_template and a dictionary xsyn
    based on it, with default parameters.  You can alter the
    parameters, for example
 
index b43907615a86fc2db59a3a9dcaa284a6d3c5010d..5b50da0510b6845ffc3b765cee8d3cafdf973076 100644 (file)
@@ -10,7 +10,7 @@
  
   The earthdistance module provides two different approaches to
   calculating great circle distances on the surface of the Earth. The one
-  described first depends on the cube package (which
+  described first depends on the cube module (which
   must be installed before earthdistance can be
   installed). The second one is based on the built-in point data type,
   using longitude and latitude for the coordinates.
index 6ccc9d664bca5ad7756330471de3be3db1b733c9..f00b06aa7aa51791395c00852adaefc5de89b6d0 100644 (file)
@@ -553,12 +553,6 @@ SELECT key, count(*) FROM
  
   Compatibility
 
-  
-   When upgrading from older versions, always load the new
-   version of this module into the database before restoring a dump.
-   Otherwise, many new features will be unavailable.
-  
-
   
    As of PostgreSQL 9.0, hstore uses a different internal
    representation than previous versions. This presents no obstacle for
index 58b37d243cd82a12591c88f11bacd2f013b127fa..8cff1020bb36be8432eef824c8070994a0a5f547 100644 (file)
   
    This view, and the function pg_stat_statements_reset,
    are available only in databases they have been specifically installed into
-   by running the pg_stat_statements.sql install script.
+   by installing the pg_stat_statements extension.
    However, statistics are tracked across all databases of the server
    whenever the pg_stat_statements module is loaded
    into the server, regardless of presence of the view.
index 65917f7d30881c820407ea67982e8c59ed9e10cb..dfb932f501a9e06ae9214ea7fb3d32ef9ef5a684 100644 (file)
@@ -345,7 +345,9 @@ FROM crosstab3(
      
       
        Create a composite type describing the desired output columns,
-       similar to the examples in the installation script. Then define a
+       similar to the examples in
+       contrib/tablefunc/tablefunc--1.0.sql.
+       Then define a
        unique function name accepting one text parameter and returning
        setof your_type_name, but linking to the same underlying
        crosstab C function.  For example, if your source data
index 0c53a3a413319888756c279f575b98b63a4c3130..0f2008cbe6b62c660e3d13cacff7d63add8e9ce2 100644 (file)
@@ -35,8 +35,8 @@ mydb=# SELECT * FROM ts_token_type('testparser');
   Usage
 
   
-   Running the installation script creates a text search parser
-   testparser.  It has no user-configurable parameters.
+   Installing the test_parser extension creates a text search
+   parser testparser.  It has no user-configurable parameters.
   
 
   
index 1933e2b966bf262d20a2def6d31183527b116ed2..8321c1efb4f4731065c47f0cb6b3d7046f5aefff 100644 (file)
      before loading the dump data!  If your old installation
      had the tsearch2 objects in a schema other
      than public, be sure to adjust the
-     <literal>tsearch2 installation script so that the replacement
+     <command>CREATE EXTENSION command so that the replacement
      objects are created in that same schema.
     
    
index 2ad66f7ee135402d915fb1ab63f62b02fbeb66c8..9c34c0bbd2e28258c559e6cb4afbd569b29bf8c9 100644 (file)
@@ -73,7 +73,7 @@
   Usage
 
   
-   Running the installation script unaccent.sql creates a text
+   Installing the unaccent extension creates a text
    search template unaccent and a dictionary unaccent
    based on it.  The unaccent dictionary has the default
    parameter setting RULES='unaccent', which makes it immediately