1CREATE TEXT SEARCH TEMPLATE(7) SQL Commands CREATE TEXT SEARCH TEMPLATE(7)
2
3
4
6 CREATE TEXT SEARCH TEMPLATE - define a new text search template
7
8
10 CREATE TEXT SEARCH TEMPLATE name (
11 [ INIT = init_function , ]
12 LEXIZE = lexize_function
13 )
14
15
17 CREATE TEXT SEARCH TEMPLATE creates a new text search template. Text
18 search templates define the functions that implement text search dic‐
19 tionaries. A template is not useful by itself, but must be instantiated
20 as a dictionary to be used. The dictionary typically specifies parame‐
21 ters to be given to the template functions.
22
23 If a schema name is given then the text search template is created in
24 the specified schema. Otherwise it is created in the current schema.
25
26 You must be a superuser to use CREATE TEXT SEARCH TEMPLATE. This
27 restriction is made because an erroneous text search template defini‐
28 tion could confuse or even crash the server. The reason for separating
29 templates from dictionaries is that a template encapsulates the
30 ``unsafe'' aspects of defining a dictionary. The parameters that can
31 be set when defining a dictionary are safe for unprivileged users to
32 set, and so creating a dictionary need not be a privileged operation.
33
34 Refer to in the documentation for further information.
35
37 name The name of the text search template to be created. The name can
38 be schema-qualified.
39
40 init_function
41 The name of the init function for the template.
42
43 lexize_function
44 The name of the lexize function for the template.
45
46 The function names can be schema-qualified if necessary. Argument types
47 are not given, since the argument list for each type of function is
48 predetermined. The lexize function is required, but the init function
49 is optional.
50
51 The arguments can appear in any order, not only the one shown above.
52
54 There is no CREATE TEXT SEARCH TEMPLATE statement in the SQL standard.
55
57 ALTER TEXT SEARCH TEMPLATE [alter_text_search_template(7)], DROP TEXT
58 SEARCH TEMPLATE [drop_text_search_template(7)]
59
60
61
62SQL - Language Statements 2014-02-17 CREATE TEXT SEARCH TEMPLATE(7)