~ubuntu-branches/ubuntu/lucid/postgresql-8.4/lucid-proposed

« back to all changes in this revision

Viewing changes to doc/src/sgml/ref/alter_tsdictionary.sgml

  • Committer: Bazaar Package Importer
  • Author(s): Martin Pitt
  • Date: 2009-03-20 12:00:13 UTC
  • Revision ID: james.westby@ubuntu.com-20090320120013-hogj7egc5mjncc5g
Tags: upstream-8.4~0cvs20090328
ImportĀ upstreamĀ versionĀ 8.4~0cvs20090328

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
<!--
 
2
$PostgreSQL$
 
3
PostgreSQL documentation
 
4
-->
 
5
 
 
6
<refentry id="SQL-ALTERTSDICTIONARY">
 
7
 <refmeta>
 
8
  <refentrytitle id="SQL-ALTERTSDICTIONARY-TITLE">ALTER TEXT SEARCH DICTIONARY</refentrytitle>
 
9
  <manvolnum>7</manvolnum>
 
10
  <refmiscinfo>SQL - Language Statements</refmiscinfo>
 
11
 </refmeta>
 
12
 
 
13
 <refnamediv>
 
14
  <refname>ALTER TEXT SEARCH DICTIONARY</refname>
 
15
  <refpurpose>change the definition of a text search dictionary</refpurpose>
 
16
 </refnamediv>  
 
17
  
 
18
 <indexterm zone="sql-altertsdictionary">
 
19
  <primary>ALTER TEXT SEARCH DICTIONARY</primary>
 
20
 </indexterm>
 
21
 
 
22
 <refsynopsisdiv>
 
23
<synopsis>
 
24
ALTER TEXT SEARCH DICTIONARY <replaceable>name</replaceable> (
 
25
    <replaceable class="parameter">option</replaceable> [ = <replaceable class="parameter">value</replaceable> ] [, ... ]
 
26
)
 
27
ALTER TEXT SEARCH DICTIONARY <replaceable>name</replaceable> RENAME TO <replaceable>newname</replaceable>
 
28
ALTER TEXT SEARCH DICTIONARY <replaceable>name</replaceable> OWNER TO <replaceable>newowner</replaceable>
 
29
</synopsis>
 
30
 </refsynopsisdiv>
 
31
  
 
32
 <refsect1>
 
33
  <title>Description</title>
 
34
 
 
35
  <para>
 
36
   <command>ALTER TEXT SEARCH DICTIONARY</command> changes the definition of
 
37
   a text search dictionary.  You can change the dictionary's
 
38
   template-specific options, or change the dictionary's name or owner.
 
39
  </para>
 
40
 
 
41
  <para>
 
42
   You must be the owner of the dictionary to use
 
43
   <command>ALTER TEXT SEARCH DICTIONARY</>.
 
44
  </para>
 
45
 </refsect1>
 
46
  
 
47
 <refsect1>
 
48
  <title>Parameters</title>
 
49
 
 
50
  <variablelist>
 
51
   <varlistentry>
 
52
    <term><replaceable class="parameter">name</replaceable></term>
 
53
    <listitem>
 
54
     <para>
 
55
      The name (optionally schema-qualified) of an existing text search
 
56
      dictionary.
 
57
     </para>
 
58
    </listitem>
 
59
   </varlistentry>
 
60
 
 
61
   <varlistentry>
 
62
    <term><replaceable class="parameter">option</replaceable></term>
 
63
    <listitem>
 
64
     <para>
 
65
      The name of a template-specific option to be set for this dictionary.
 
66
     </para>
 
67
    </listitem>
 
68
   </varlistentry>
 
69
 
 
70
   <varlistentry>
 
71
    <term><replaceable class="parameter">value</replaceable></term>
 
72
    <listitem>
 
73
     <para>
 
74
      The new value to use for a template-specific option.
 
75
      If the equal sign and value are omitted, then any previous
 
76
      setting for the option is removed from the dictionary,
 
77
      allowing the default to be used.
 
78
     </para>
 
79
    </listitem>
 
80
   </varlistentry>
 
81
 
 
82
   <varlistentry>
 
83
    <term><replaceable class="parameter">newname</replaceable></term>
 
84
    <listitem>
 
85
     <para>
 
86
      The new name of the text search dictionary.
 
87
     </para>
 
88
    </listitem>
 
89
   </varlistentry>
 
90
 
 
91
   <varlistentry>
 
92
    <term><replaceable class="parameter">newowner</replaceable></term>
 
93
    <listitem>
 
94
     <para>
 
95
      The new owner of the text search dictionary.
 
96
     </para>
 
97
    </listitem>
 
98
   </varlistentry>
 
99
 </variablelist>
 
100
 
 
101
  <para>
 
102
   Template-specific options can appear in any order.
 
103
  </para>
 
104
 </refsect1>
 
105
  
 
106
 <refsect1>
 
107
  <title>Examples</title>
 
108
 
 
109
  <para>
 
110
   The following example command changes the stopword list
 
111
   for a Snowball-based dictionary.  Other parameters remain unchanged.
 
112
  </para>
 
113
 
 
114
<programlisting>
 
115
ALTER TEXT SEARCH DICTIONARY my_dict ( StopWords = newrussian );
 
116
</programlisting>  
 
117
 
 
118
  <para>
 
119
   The following example command changes the language option to dutch,
 
120
   and removes the stopword option entirely.
 
121
  </para>
 
122
 
 
123
<programlisting>
 
124
ALTER TEXT SEARCH DICTIONARY my_dict ( language = dutch, StopWords );
 
125
</programlisting>  
 
126
 
 
127
  <para>
 
128
   The following example command <quote>updates</> the dictionary's
 
129
   definition without actually changing anything.
 
130
 
 
131
<programlisting>
 
132
ALTER TEXT SEARCH DICTIONARY my_dict ( dummy );
 
133
</programlisting>
 
134
 
 
135
   (The reason this works is that the option removal code doesn't complain
 
136
   if there is no such option.)  This trick is useful when changing
 
137
   configuration files for the dictionary: the <command>ALTER</> will
 
138
   force existing database sessions to re-read the configuration files,
 
139
   which otherwise they would never do if they had read them earlier.
 
140
  </para>
 
141
 </refsect1>
 
142
 
 
143
 <refsect1>
 
144
  <title>Compatibility</title>
 
145
 
 
146
  <para>
 
147
   There is no <command>ALTER TEXT SEARCH DICTIONARY</command> statement in
 
148
   the SQL standard.
 
149
  </para>
 
150
 </refsect1>
 
151
 
 
152
 <refsect1>
 
153
  <title>See Also</title>
 
154
 
 
155
  <simplelist type="inline">
 
156
   <member><xref linkend="sql-createtsdictionary" endterm="sql-createtsdictionary-title"></member>
 
157
   <member><xref linkend="sql-droptsdictionary" endterm="sql-droptsdictionary-title"></member>
 
158
  </simplelist>
 
159
 </refsect1>
 
160
</refentry>