Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit c43d26c

Browse files
committed
Adjust some more places in the documentation to match the fact that
plpgsql is now installed by default.
1 parent efc16ea commit c43d26c

File tree

4 files changed

+44
-32
lines changed

4 files changed

+44
-32
lines changed

doc/src/sgml/manage-ag.sgml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<!-- $PostgreSQL: pgsql/doc/src/sgml/manage-ag.sgml,v 2.59 2009/12/10 06:32:27 petere Exp $ -->
1+
<!-- $PostgreSQL: pgsql/doc/src/sgml/manage-ag.sgml,v 2.60 2009/12/19 01:49:02 tgl Exp $ -->
22

33
<chapter id="managing-databases">
44
<title>Managing Databases</title>
@@ -184,7 +184,7 @@ createdb -O <replaceable>rolename</> <replaceable>dbname</>
184184
will be copied into subsequently created user databases. This
185185
behavior allows site-local modifications to the standard set of
186186
objects in databases. For example, if you install the procedural
187-
language <application>PL/pgSQL</> in <literal>template1</>, it will
187+
language <application>PL/Perl</> in <literal>template1</>, it will
188188
automatically be available in user databases without any extra
189189
action being taken when those databases are made.
190190
</para>

doc/src/sgml/plpgsql.sgml

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<!-- $PostgreSQL: pgsql/doc/src/sgml/plpgsql.sgml,v 1.147 2009/11/13 22:43:39 tgl Exp $ -->
1+
<!-- $PostgreSQL: pgsql/doc/src/sgml/plpgsql.sgml,v 1.148 2009/12/19 01:49:02 tgl Exp $ -->
22

33
<chapter id="plpgsql">
44
<title><application>PL/pgSQL</application> - <acronym>SQL</acronym> Procedural Language</title>
@@ -58,6 +58,13 @@
5858
them to define operators or use them in index expressions.
5959
</para>
6060

61+
<para>
62+
In <productname>PostgreSQL</> 8.5 and later,
63+
<application>PL/pgSQL</application> is installed by default.
64+
However it is still a loadable module, so especially security-conscious
65+
administrators could choose to remove it.
66+
</para>
67+
6168
<sect2 id="plpgsql-advantages">
6269
<title>Advantages of Using <application>PL/pgSQL</application></title>
6370

doc/src/sgml/ref/create_language.sgml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<!--
2-
$PostgreSQL: pgsql/doc/src/sgml/ref/create_language.sgml,v 1.47 2009/10/08 04:41:07 tgl Exp $
2+
$PostgreSQL: pgsql/doc/src/sgml/ref/create_language.sgml,v 1.48 2009/12/19 01:49:02 tgl Exp $
33
PostgreSQL documentation
44
-->
55

@@ -266,7 +266,7 @@ CREATE [ TRUSTED ] [ PROCEDURAL ] LANGUAGE <replaceable class="parameter">name</
266266
The preferred way of creating any of the standard procedural languages
267267
is just:
268268
<programlisting>
269-
CREATE LANGUAGE plpgsql;
269+
CREATE LANGUAGE plperl;
270270
</programlisting>
271271
</para>
272272

doc/src/sgml/xplang.sgml

Lines changed: 32 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<!-- $PostgreSQL: pgsql/doc/src/sgml/xplang.sgml,v 1.35 2009/09/22 23:43:37 tgl Exp $ -->
1+
<!-- $PostgreSQL: pgsql/doc/src/sgml/xplang.sgml,v 1.36 2009/12/19 01:49:02 tgl Exp $ -->
22

33
<chapter id="xplang">
44
<title id="xplang-title">Procedural Languages</title>
@@ -33,8 +33,8 @@
3333
<application>PL/Python</application> (<xref linkend="plpython">).
3434
There are additional procedural languages available that are not
3535
included in the core distribution. <xref linkend="external-projects">
36-
has information about finding them. In addition other languages can
37-
be defined by users; the basics of developing a new procedural
36+
has information about finding them. In addition other languages can
37+
be defined by users; the basics of developing a new procedural
3838
language are covered in <xref linkend="plhandler">.
3939
</para>
4040

@@ -59,10 +59,10 @@
5959
current database. Alternatively, the program <xref
6060
linkend="app-createlang"> can be used to do this from the shell
6161
command line. For example, to install the language
62-
<application>PL/pgSQL</application> into the database
62+
<application>PL/Perl</application> into the database
6363
<literal>template1</>, use:
6464
<programlisting>
65-
createlang plpgsql template1
65+
createlang plperl template1
6666
</programlisting>
6767
The manual procedure described below is only recommended for
6868
installing custom languages that <command>CREATE LANGUAGE</command>
@@ -173,59 +173,64 @@ CREATE <optional>TRUSTED</optional> <optional>PROCEDURAL</optional> LANGUAGE <re
173173
<para>
174174
<xref linkend="xplang-install-example"> shows how the manual
175175
installation procedure would work with the language
176-
<application>PL/pgSQL</application>.
176+
<application>PL/Perl</application>.
177177
</para>
178178

179179
<example id="xplang-install-example">
180-
<title>Manual Installation of <application>PL/pgSQL</application></title>
180+
<title>Manual Installation of <application>PL/Perl</application></title>
181181

182182
<para>
183-
The following command tells the database server where to find the
184-
shared object for the <application>PL/pgSQL</application> language's call handler function.
183+
The following command tells the database server where to find the
184+
shared object for the <application>PL/Perl</application> language's call
185+
handler function:
185186

186187
<programlisting>
187-
CREATE FUNCTION plpgsql_call_handler() RETURNS language_handler AS
188-
'$libdir/plpgsql' LANGUAGE C;
188+
CREATE FUNCTION plperl_call_handler() RETURNS language_handler AS
189+
'$libdir/plperl' LANGUAGE C;
189190
</programlisting>
190191
</para>
191192

192193
<para>
193-
<application>PL/pgSQL</application> has an inline handler function
194+
<application>PL/Perl</application> has an inline handler function
194195
and a validator function, so we declare those too:
195196

196197
<programlisting>
197-
CREATE FUNCTION plpgsql_inline_handler(internal) RETURNS void AS
198-
'$libdir/plpgsql' LANGUAGE C;
198+
CREATE FUNCTION plperl_inline_handler(internal) RETURNS void AS
199+
'$libdir/plperl' LANGUAGE C;
199200

200-
CREATE FUNCTION plpgsql_validator(oid) RETURNS void AS
201-
'$libdir/plpgsql' LANGUAGE C;
201+
CREATE FUNCTION plperl_validator(oid) RETURNS void AS
202+
'$libdir/plperl' LANGUAGE C;
202203
</programlisting>
203204
</para>
204205

205206
<para>
206207
The command:
207208
<programlisting>
208-
CREATE TRUSTED PROCEDURAL LANGUAGE plpgsql
209-
HANDLER plpgsql_call_handler
210-
INLINE plpgsql_inline_handler
211-
VALIDATOR plpgsql_validator;
209+
CREATE TRUSTED PROCEDURAL LANGUAGE plperl
210+
HANDLER plperl_call_handler
211+
INLINE plperl_inline_handler
212+
VALIDATOR plperl_validator;
212213
</programlisting>
213214
then defines that the previously declared functions
214215
should be invoked for functions and trigger procedures where the
215-
language attribute is <literal>plpgsql</literal>.
216+
language attribute is <literal>plperl</literal>.
216217
</para>
217218
</example>
218219

219220
<para>
220221
In a default <productname>PostgreSQL</productname> installation,
221222
the handler for the <application>PL/pgSQL</application> language
222223
is built and installed into the <quote>library</quote>
223-
directory. If <application>Tcl</> support is configured in, the handlers
224-
for <application>PL/Tcl</> and <application>PL/TclU</> are also built and
225-
installed in the same location. Likewise, the <application>PL/Perl</> and
226-
<application>PL/PerlU</> handlers are built and installed if Perl support
227-
is configured, and the <application>PL/PythonU</> handler is
228-
installed if Python support is configured.
224+
directory; furthermore, the <application>PL/pgSQL</application> language
225+
itself is installed in all databases.
226+
If <application>Tcl</> support is configured in, the handlers for
227+
<application>PL/Tcl</> and <application>PL/TclU</> are built and installed
228+
in the library directory, but the language itself is not installed in any
229+
database by default.
230+
Likewise, the <application>PL/Perl</> and <application>PL/PerlU</>
231+
handlers are built and installed if Perl support is configured, and the
232+
<application>PL/PythonU</> handler is installed if Python support is
233+
configured, but these languages are not installed by default.
229234
</para>
230235

231236
</sect1>

0 commit comments

Comments
 (0)