CREATE_TEXT_SEARCH_DICTIONARY(7pg14)
β¨ CREATE_TEXT_SEARCH_DICTIONARY β define a new text search dictionary β¨
Okay bestie, we're in the CREATE_TEXT_SEARCH_DICTIONARY(7) page, PostgreSQL 14.24 Documentation era, and this one is literally about making your very own text search dictionary. It's giving "custom word vibes" and I am obsessed. π
πΈ NAME πΈ
CREATE_TEXT_SEARCH_DICTIONARY β define a new text search dictionary
π¦ SYNOPSIS π¦
CREATE TEXT SEARCH DICTIONARY name (
TEMPLATE = template
[, option = value [, ... ]]
)
π DESCRIPTION π
So, CREATE TEXT_SEARCH_DICTIONARYβ¦ wait, no, it's CREATE TEXT_SEARCH_DICTIONARY? Nope. The actual command is CREATE TEXT_SEARCH_DICTIONARY? Let me breathe. It's CREATE TEXT_SEARCH_DICTIONARYβokay I keep doing that. The real one is CREATE TEXT SEARCH DICTIONARY (spaces, bestie, spaces). And what it does is create a new text search dictionary. No cap. π
A text search dictionary specifies a way of recognizing interesting or uninteresting words for searching. It's literally the vibe-checker for which words matter. The way that a dictionary depends on a text search template? That template specifies the functions that actually perform the work. So the dictionary is like the main character, but the template is the whole production crew behind her. π¬
Typically the dictionary provides some options that control the detailed behavior of the template's functions.
If a schema name is given, then the text search dictionary is created in the specified schema. Otherwise it's created in the current schema.
The user who defines a text search dictionary becomes its owner. Slay, ownership era. π
Refer to Chapter 12 for further information. (iykyk π)
π PARAMETERS π
nameβ the name of the text search dictionary to be created. The name can be schema-qualified. π·οΈtemplateβ the name of the text search template that will define the basic behavior of this dictionary. This is the blueprint, the moment, the foundation.optionβ the name of a template-specific option to be set for this dictionary. Customization queen.valueβ the value to use for a template-specific option. If the value is not a simple identifier or number, it must be quoted (but you can always quote it, if you wish). Do it for the plot, honestly. π
The options can appear in any order. No rules, just right. β¨
π₯ EXAMPLES π₯
This next example command creates a Snowball-based dictionary with a nonstandard list of stop words. We love a nonstandard stop word list, fr fr.
CREATE TEXT SEARCH DICTIONARY my_russian (
template = snowball,
language = russian,
stopwords = myrussian
);
π COMPATIBILITY π
There is no CREATE TEXT SEARCH DICTIONARY statement in the SQL standard. Not a single crumb. The standard simply did not serve. π
π«Ά SEE ALSO π«Ά
ALTER TEXT SEARCH DICTIONARY(ALTER_TEXT_SEARCH_DICTIONARY(7))DROP TEXT SEARCH DICTIONARY(DROP_TEXT_SEARCH_DICTIONARY(7))
And that's the whole page, bestie. This was PostgreSQL 14.24, dated 2026 β catch you on the next manpage, mwah. πππ·
π¦ where this page comes from
- opensuse-leap 16.0: postgresql14 14.24-160000.1.1 Β· PostgreSQL
- opensuse-leap 16.0: postgresql14 14.24-160000.1.1 Β· PostgreSQL
- opensuse-leap 16.0: postgresql14 14.24-160000.1.1 Β· PostgreSQL
- opensuse-leap 16.0: postgresql14 14.24-160000.1.1 Β· PostgreSQL
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms