~ubuntu-branches/ubuntu/oneiric/postgresql-9.1/oneiric-security

« back to all changes in this revision

Viewing changes to doc/src/sgml/html/sql-createtsparser.html

  • Committer: Bazaar Package Importer
  • Author(s): Martin Pitt
  • Date: 2011-05-11 10:41:53 UTC
  • Revision ID: james.westby@ubuntu.com-20110511104153-psbh2o58553fv1m0
Tags: upstream-9.1~beta1
ImportĀ upstreamĀ versionĀ 9.1~beta1

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
 
2
<HTML
 
3
><HEAD
 
4
><TITLE
 
5
>CREATE TEXT SEARCH PARSER</TITLE
 
6
><META
 
7
NAME="GENERATOR"
 
8
CONTENT="Modular DocBook HTML Stylesheet Version 1.79"><LINK
 
9
REV="MADE"
 
10
HREF="mailto:pgsql-docs@postgresql.org"><LINK
 
11
REL="HOME"
 
12
TITLE="PostgreSQL 9.1beta1 Documentation"
 
13
HREF="index.html"><LINK
 
14
REL="UP"
 
15
TITLE="SQL Commands"
 
16
HREF="sql-commands.html"><LINK
 
17
REL="PREVIOUS"
 
18
TITLE="CREATE TEXT SEARCH DICTIONARY"
 
19
HREF="sql-createtsdictionary.html"><LINK
 
20
REL="NEXT"
 
21
TITLE="CREATE TEXT SEARCH TEMPLATE"
 
22
HREF="sql-createtstemplate.html"><LINK
 
23
REL="STYLESHEET"
 
24
TYPE="text/css"
 
25
HREF="stylesheet.css"><META
 
26
HTTP-EQUIV="Content-Type"
 
27
CONTENT="text/html; charset=ISO-8859-1"><META
 
28
NAME="creation"
 
29
CONTENT="2011-04-27T21:20:33"></HEAD
 
30
><BODY
 
31
CLASS="REFENTRY"
 
32
><DIV
 
33
CLASS="NAVHEADER"
 
34
><TABLE
 
35
SUMMARY="Header navigation table"
 
36
WIDTH="100%"
 
37
BORDER="0"
 
38
CELLPADDING="0"
 
39
CELLSPACING="0"
 
40
><TR
 
41
><TH
 
42
COLSPAN="5"
 
43
ALIGN="center"
 
44
VALIGN="bottom"
 
45
><A
 
46
HREF="index.html"
 
47
>PostgreSQL 9.1beta1 Documentation</A
 
48
></TH
 
49
></TR
 
50
><TR
 
51
><TD
 
52
WIDTH="10%"
 
53
ALIGN="left"
 
54
VALIGN="top"
 
55
><A
 
56
TITLE="CREATE TEXT SEARCH DICTIONARY"
 
57
HREF="sql-createtsdictionary.html"
 
58
ACCESSKEY="P"
 
59
>Prev</A
 
60
></TD
 
61
><TD
 
62
WIDTH="10%"
 
63
ALIGN="left"
 
64
VALIGN="top"
 
65
><A
 
66
TITLE="CREATE TEXT SEARCH DICTIONARY"
 
67
HREF="sql-createtsdictionary.html"
 
68
>Fast Backward</A
 
69
></TD
 
70
><TD
 
71
WIDTH="60%"
 
72
ALIGN="center"
 
73
VALIGN="bottom"
 
74
></TD
 
75
><TD
 
76
WIDTH="10%"
 
77
ALIGN="right"
 
78
VALIGN="top"
 
79
><A
 
80
TITLE="CREATE TEXT SEARCH TEMPLATE"
 
81
HREF="sql-createtstemplate.html"
 
82
>Fast Forward</A
 
83
></TD
 
84
><TD
 
85
WIDTH="10%"
 
86
ALIGN="right"
 
87
VALIGN="top"
 
88
><A
 
89
TITLE="CREATE TEXT SEARCH TEMPLATE"
 
90
HREF="sql-createtstemplate.html"
 
91
ACCESSKEY="N"
 
92
>Next</A
 
93
></TD
 
94
></TR
 
95
></TABLE
 
96
><HR
 
97
ALIGN="LEFT"
 
98
WIDTH="100%"></DIV
 
99
><H1
 
100
><A
 
101
NAME="SQL-CREATETSPARSER"
 
102
></A
 
103
>CREATE TEXT SEARCH PARSER</H1
 
104
><DIV
 
105
CLASS="REFNAMEDIV"
 
106
><A
 
107
NAME="AEN68309"
 
108
></A
 
109
><H2
 
110
>Name</H2
 
111
>CREATE TEXT SEARCH PARSER&nbsp;--&nbsp;define a new text search parser</DIV
 
112
><DIV
 
113
CLASS="REFSYNOPSISDIV"
 
114
><A
 
115
NAME="AEN68314"
 
116
></A
 
117
><H2
 
118
>Synopsis</H2
 
119
><PRE
 
120
CLASS="SYNOPSIS"
 
121
>CREATE TEXT SEARCH PARSER <TT
 
122
CLASS="REPLACEABLE"
 
123
><I
 
124
>name</I
 
125
></TT
 
126
> (
 
127
    START = <TT
 
128
CLASS="REPLACEABLE"
 
129
><I
 
130
>start_function</I
 
131
></TT
 
132
> ,
 
133
    GETTOKEN = <TT
 
134
CLASS="REPLACEABLE"
 
135
><I
 
136
>gettoken_function</I
 
137
></TT
 
138
> ,
 
139
    END = <TT
 
140
CLASS="REPLACEABLE"
 
141
><I
 
142
>end_function</I
 
143
></TT
 
144
> ,
 
145
    LEXTYPES = <TT
 
146
CLASS="REPLACEABLE"
 
147
><I
 
148
>lextypes_function</I
 
149
></TT
 
150
>
 
151
    [, HEADLINE = <TT
 
152
CLASS="REPLACEABLE"
 
153
><I
 
154
>headline_function</I
 
155
></TT
 
156
> ]
 
157
)</PRE
 
158
></DIV
 
159
><DIV
 
160
CLASS="REFSECT1"
 
161
><A
 
162
NAME="AEN68322"
 
163
></A
 
164
><H2
 
165
>Description</H2
 
166
><P
 
167
>   <TT
 
168
CLASS="COMMAND"
 
169
>CREATE TEXT SEARCH PARSER</TT
 
170
> creates a new text search
 
171
   parser.  A text search parser defines a method for splitting a text
 
172
   string into tokens and assigning types (categories) to the tokens.
 
173
   A parser is not particularly useful by itself, but must be bound into a
 
174
   text search configuration along with some text search dictionaries
 
175
   to be used for searching.
 
176
  </P
 
177
><P
 
178
>   If a schema name is given then the text search parser is created in the
 
179
   specified schema.  Otherwise it is created in the current schema.
 
180
  </P
 
181
><P
 
182
>   You must be a superuser to use <TT
 
183
CLASS="COMMAND"
 
184
>CREATE TEXT SEARCH PARSER</TT
 
185
>.
 
186
   (This restriction is made because an erroneous text search parser
 
187
   definition could confuse or even crash the server.)
 
188
  </P
 
189
><P
 
190
>   Refer to <A
 
191
HREF="textsearch.html"
 
192
>Chapter 12</A
 
193
> for further information.
 
194
  </P
 
195
></DIV
 
196
><DIV
 
197
CLASS="REFSECT1"
 
198
><A
 
199
NAME="AEN68331"
 
200
></A
 
201
><H2
 
202
>Parameters</H2
 
203
><P
 
204
></P
 
205
><DIV
 
206
CLASS="VARIABLELIST"
 
207
><DL
 
208
><DT
 
209
><TT
 
210
CLASS="REPLACEABLE"
 
211
><I
 
212
>name</I
 
213
></TT
 
214
></DT
 
215
><DD
 
216
><P
 
217
>      The name of the text search parser to be created.  The name can be
 
218
      schema-qualified.
 
219
     </P
 
220
></DD
 
221
><DT
 
222
><TT
 
223
CLASS="REPLACEABLE"
 
224
><I
 
225
>start_function</I
 
226
></TT
 
227
></DT
 
228
><DD
 
229
><P
 
230
>      The name of the start function for the parser.
 
231
     </P
 
232
></DD
 
233
><DT
 
234
><TT
 
235
CLASS="REPLACEABLE"
 
236
><I
 
237
>gettoken_function</I
 
238
></TT
 
239
></DT
 
240
><DD
 
241
><P
 
242
>      The name of the get-next-token function for the parser.
 
243
     </P
 
244
></DD
 
245
><DT
 
246
><TT
 
247
CLASS="REPLACEABLE"
 
248
><I
 
249
>end_function</I
 
250
></TT
 
251
></DT
 
252
><DD
 
253
><P
 
254
>      The name of the end function for the parser.
 
255
     </P
 
256
></DD
 
257
><DT
 
258
><TT
 
259
CLASS="REPLACEABLE"
 
260
><I
 
261
>lextypes_function</I
 
262
></TT
 
263
></DT
 
264
><DD
 
265
><P
 
266
>      The name of the lextypes function for the parser (a function that
 
267
      returns information about the set of token types it produces).
 
268
     </P
 
269
></DD
 
270
><DT
 
271
><TT
 
272
CLASS="REPLACEABLE"
 
273
><I
 
274
>headline_function</I
 
275
></TT
 
276
></DT
 
277
><DD
 
278
><P
 
279
>      The name of the headline function for the parser (a function that
 
280
      summarizes a set of tokens).
 
281
     </P
 
282
></DD
 
283
></DL
 
284
></DIV
 
285
><P
 
286
>   The function names can be schema-qualified if necessary.  Argument types
 
287
   are not given, since the argument list for each type of function is
 
288
   predetermined.  All except the headline function are required.
 
289
  </P
 
290
><P
 
291
>   The arguments can appear in any order, not only the one shown above.
 
292
  </P
 
293
></DIV
 
294
><DIV
 
295
CLASS="REFSECT1"
 
296
><A
 
297
NAME="AEN68366"
 
298
></A
 
299
><H2
 
300
>Compatibility</H2
 
301
><P
 
302
>   There is no
 
303
   <TT
 
304
CLASS="COMMAND"
 
305
>CREATE TEXT SEARCH PARSER</TT
 
306
> statement in the SQL
 
307
   standard.
 
308
  </P
 
309
></DIV
 
310
><DIV
 
311
CLASS="REFSECT1"
 
312
><A
 
313
NAME="AEN68370"
 
314
></A
 
315
><H2
 
316
>See Also</H2
 
317
><A
 
318
HREF="sql-altertsparser.html"
 
319
>ALTER TEXT SEARCH PARSER</A
 
320
>, <A
 
321
HREF="sql-droptsparser.html"
 
322
>DROP TEXT SEARCH PARSER</A
 
323
></DIV
 
324
><DIV
 
325
CLASS="NAVFOOTER"
 
326
><HR
 
327
ALIGN="LEFT"
 
328
WIDTH="100%"><TABLE
 
329
SUMMARY="Footer navigation table"
 
330
WIDTH="100%"
 
331
BORDER="0"
 
332
CELLPADDING="0"
 
333
CELLSPACING="0"
 
334
><TR
 
335
><TD
 
336
WIDTH="33%"
 
337
ALIGN="left"
 
338
VALIGN="top"
 
339
><A
 
340
HREF="sql-createtsdictionary.html"
 
341
ACCESSKEY="P"
 
342
>Prev</A
 
343
></TD
 
344
><TD
 
345
WIDTH="34%"
 
346
ALIGN="center"
 
347
VALIGN="top"
 
348
><A
 
349
HREF="index.html"
 
350
ACCESSKEY="H"
 
351
>Home</A
 
352
></TD
 
353
><TD
 
354
WIDTH="33%"
 
355
ALIGN="right"
 
356
VALIGN="top"
 
357
><A
 
358
HREF="sql-createtstemplate.html"
 
359
ACCESSKEY="N"
 
360
>Next</A
 
361
></TD
 
362
></TR
 
363
><TR
 
364
><TD
 
365
WIDTH="33%"
 
366
ALIGN="left"
 
367
VALIGN="top"
 
368
>CREATE TEXT SEARCH DICTIONARY</TD
 
369
><TD
 
370
WIDTH="34%"
 
371
ALIGN="center"
 
372
VALIGN="top"
 
373
><A
 
374
HREF="sql-commands.html"
 
375
ACCESSKEY="U"
 
376
>Up</A
 
377
></TD
 
378
><TD
 
379
WIDTH="33%"
 
380
ALIGN="right"
 
381
VALIGN="top"
 
382
>CREATE TEXT SEARCH TEMPLATE</TD
 
383
></TR
 
384
></TABLE
 
385
></DIV
 
386
></BODY
 
387
></HTML
 
388
>
 
 
b'\\ No newline at end of file'