Creates a text search dictionary.
Synopsis
CREATE TEXT SEARCH DICTIONARY name (
TEMPLATE = template
[, option = value [, ... ]]
)Description
A text search dictionary defines how the search engine recognizes and classifies tokens — marking some as meaningful and others (such as stop words) as ignorable. Each dictionary is backed by a text search template, which provides the underlying functions. The dictionary's options control the detailed behavior of those functions.
If you include a schema name, the dictionary is created in that schema. Otherwise, it is created in the current schema. The user who creates the dictionary becomes its owner.
Note
Options can appear in any order.
Parameters
| Parameter | Description |
|---|---|
name | The name of the dictionary to create. The name can be schema-qualified. |
template | The text search template that defines the dictionary's behavior. |
option | A template-specific option name. |
value | The value for the option. Quote the value if it is not a simple identifier or number. |
Examples
Create a Snowball-based dictionary for Russian with a nonstandard list of stop words:
CREATE TEXT SEARCH DICTIONARY my_russian (
template = snowball,
language = russian,
stopwords = myrussian
);