]> granicus.if.org Git - postgresql/blob - doc/src/sgml/ref/droplang.sgml
Allow for parallel execution whenever ExecutorRun() is done only once.
[postgresql] / doc / src / sgml / ref / droplang.sgml
1 <!--
2 doc/src/sgml/ref/droplang.sgml
3 PostgreSQL documentation
4 -->
5
6 <refentry id="APP-DROPLANG">
7  <indexterm zone="app-droplang">
8   <primary>droplang</primary>
9  </indexterm>
10
11  <refmeta>
12   <refentrytitle><application>droplang</application></refentrytitle>
13   <manvolnum>1</manvolnum>
14   <refmiscinfo>Application</refmiscinfo>
15  </refmeta>
16
17  <refnamediv>
18   <refname>droplang</refname>
19   <refpurpose>remove a <productname>PostgreSQL</productname> procedural language</refpurpose>
20  </refnamediv>
21
22  <refsynopsisdiv>
23   <cmdsynopsis>
24    <command>droplang</command>
25    <arg rep="repeat"><replaceable>connection-option</replaceable></arg>
26    <arg choice="plain"><replaceable>langname</replaceable></arg>
27    <arg choice="opt"><replaceable>dbname</replaceable></arg>
28   </cmdsynopsis>
29
30   <cmdsynopsis>
31    <command>droplang</command>
32    <arg rep="repeat"><replaceable>connection-option</replaceable></arg>
33    <group choice="plain"><arg choice="plain"><option>--list</option></arg><arg choice="plain"><option>-l</option></arg></group>
34    <arg choice="opt"><replaceable>dbname</replaceable></arg>
35   </cmdsynopsis>
36  </refsynopsisdiv>
37
38  <refsect1 id="R1-APP-DROPLANG-1">
39   <title>
40    Description
41   </title>
42
43   <para>
44    <application>droplang</application> is a utility for removing an
45    existing procedural language from a
46    <productname>PostgreSQL</productname> database.
47   </para>
48
49   <para>
50    <application>droplang</application> is just a wrapper around the
51    <xref linkend="sql-dropextension"> SQL command.
52   </para>
53
54   <caution>
55    <para>
56     <application>droplang</application> is deprecated and may be removed
57     in a future <productname>PostgreSQL</productname> release.  Direct use
58     of the <command>DROP EXTENSION</> command is recommended instead.
59    </para>
60   </caution>
61  </refsect1>
62
63
64  <refsect1>
65   <title>Options</title>
66
67    <para>
68     <application>droplang</application> accepts the following command line arguments:
69
70     <variablelist>
71      <varlistentry>
72       <term><replaceable class="parameter">langname</replaceable></term>
73       <listitem>
74        <para>
75         Specifies the name of the procedural language to be removed.
76         (This name is lower-cased.)
77        </para>
78       </listitem>
79      </varlistentry>
80
81      <varlistentry>
82       <term><option><optional>-d</> <replaceable class="parameter">dbname</replaceable></></term>
83       <term><option><optional>--dbname=</><replaceable class="parameter">dbname</replaceable></></term>
84       <listitem>
85        <para>
86         Specifies from which database the language should be removed.
87         The default is to use the database with the same name as the
88         current system user.
89        </para>
90       </listitem>
91      </varlistentry>
92
93      <varlistentry>
94       <term><option>-e</></term>
95       <term><option>--echo</></term>
96       <listitem>
97        <para>
98         Display SQL commands as they are executed.
99        </para>
100       </listitem>
101      </varlistentry>
102
103      <varlistentry>
104       <term><option>-l</></term>
105       <term><option>--list</></term>
106       <listitem>
107        <para>
108         Show a list of already installed languages in the target database.
109        </para>
110       </listitem>
111      </varlistentry>
112
113      <varlistentry>
114        <term><option>-V</></term>
115        <term><option>--version</></term>
116        <listitem>
117        <para>
118        Print the <application>droplang</application> version and exit.
119        </para>
120        </listitem>
121      </varlistentry>
122
123      <varlistentry>
124        <term><option>-?</></term>
125        <term><option>--help</></term>
126        <listitem>
127        <para>
128        Show help about <application>droplang</application> command line
129        arguments, and exit.
130        </para>
131        </listitem>
132      </varlistentry>
133
134     </variablelist>
135    </para>
136
137    <para>
138     <application>droplang</application> also accepts
139     the following command line arguments for connection parameters:
140
141     <variablelist>
142      <varlistentry>
143       <term><option>-h <replaceable class="parameter">host</replaceable></></term>
144       <term><option>--host=<replaceable class="parameter">host</replaceable></></term>
145       <listitem>
146        <para>
147         Specifies the host name of the machine on which the
148         server
149         is running.  If host begins with a slash, it is used
150         as the directory for the Unix domain socket.
151        </para>
152       </listitem>
153      </varlistentry>
154
155      <varlistentry>
156       <term><option>-p <replaceable class="parameter">port</replaceable></></term>
157       <term><option>--port=<replaceable class="parameter">port</replaceable></></term>
158       <listitem>
159        <para>
160         Specifies the Internet TCP/IP port or local Unix domain socket file
161         extension on which the server
162         is listening for connections.
163        </para>
164       </listitem>
165      </varlistentry>
166
167      <varlistentry>
168       <term><option>-U <replaceable class="parameter">username</replaceable></></term>
169       <term><option>--username=<replaceable class="parameter">username</replaceable></></term>
170       <listitem>
171        <para>
172         User name to connect as.
173        </para>
174       </listitem>
175      </varlistentry>
176
177      <varlistentry>
178       <term><option>-w</></term>
179       <term><option>--no-password</></term>
180       <listitem>
181        <para>
182         Never issue a password prompt.  If the server requires
183         password authentication and a password is not available by
184         other means such as a <filename>.pgpass</filename> file, the
185         connection attempt will fail.  This option can be useful in
186         batch jobs and scripts where no user is present to enter a
187         password.
188        </para>
189       </listitem>
190      </varlistentry>
191
192      <varlistentry>
193       <term><option>-W</></term>
194       <term><option>--password</></term>
195       <listitem>
196        <para>
197         Force <application>droplang</application> to prompt for a
198         password before connecting to a database.
199        </para>
200
201        <para>
202         This option is never essential, since
203         <application>droplang</application> will automatically prompt
204         for a password if the server demands password authentication.
205         However, <application>droplang</application> will waste a
206         connection attempt finding out that the server wants a password.
207         In some cases it is worth typing <option>-W</> to avoid the extra
208         connection attempt.
209        </para>
210       </listitem>
211      </varlistentry>
212
213     </variablelist>
214    </para>
215  </refsect1>
216
217
218  <refsect1>
219   <title>Environment</title>
220
221   <variablelist>
222    <varlistentry>
223     <term><envar>PGDATABASE</envar></term>
224     <term><envar>PGHOST</envar></term>
225     <term><envar>PGPORT</envar></term>
226     <term><envar>PGUSER</envar></term>
227
228     <listitem>
229      <para>
230       Default connection parameters
231      </para>
232     </listitem>
233    </varlistentry>
234   </variablelist>
235
236   <para>
237    This utility, like most other <productname>PostgreSQL</> utilities,
238    also uses the environment variables supported by <application>libpq</>
239    (see <xref linkend="libpq-envars">).
240   </para>
241
242  </refsect1>
243
244
245  <refsect1>
246    <title>Diagnostics</title>
247
248    <para>
249     Most error messages are self-explanatory. If not, run
250     <application>droplang</application> with the <option>--echo</option>
251     option and see under the respective <acronym>SQL</acronym> command
252     for details.  Also, any default connection settings and environment
253     variables used by the <application>libpq</application> front-end
254     library will apply.
255    </para>
256  </refsect1>
257
258
259  <refsect1>
260   <title>Notes</title>
261
262   <para>
263    Use <xref linkend="app-createlang"> to add a language.
264   </para>
265  </refsect1>
266
267
268  <refsect1>
269   <title>Examples</title>
270
271    <para>
272     To remove the language <literal>pltcl</literal>:
273 <screen>
274 <prompt>$ </prompt><userinput>droplang pltcl dbname</userinput>
275 </screen></para>
276  </refsect1>
277
278  <refsect1>
279   <title>See Also</title>
280
281   <simplelist type="inline">
282    <member><xref linkend="app-createlang"></member>
283    <member><xref linkend="sql-dropextension"></member>
284    <member><xref linkend="sql-droplanguage"></member>
285   </simplelist>
286  </refsect1>
287
288 </refentry>