CREATE FULLTEXT MAPPING

Name

CREATE FULLTEXT MAPPING -- binds tokens and dictionaries

Synopsis

CREATE FULLTEXT MAPPING ON cfgname FOR tokentypename[, ...] WITH dictname1[, ...];
  

Description

CREATE FULLTEXT MAPPING bind token of type lexemetypename and full-text dictionaries in given configuration cfgname. The order of dictionaries is important, since lexeme processed in that order.

Parameters

cfgname

The name (optionally schema-qualified) of the full-text configuration.

FOR

tokentypename is the type of token full-text mapping created for.

WITH

dictname1 is the name of full-text dictionary, which binds to the tokentypename.

Examples

In example below, we first create testcfg full-text configuration and then create mapping for token of types lword,lhword,lpart_hword.

=# CREATE FULLTEXT CONFIGURATION testcfg LOCALE  'testlocale'  LIKE russian_utf8;
CREATE FULLTEXT CONFIGURATION
=# CREATE FULLTEXT MAPPING ON testcfg FOR lword,lhword,lpart_hword WITH simple,en_stem;
CREATE FULLTEXT MAPPING
=# \dF+ testcfg
Configuration 'testcfg'
Parser name: 'default'
Locale: 'testlocale'
     Token   |  Dictionaries
-------------+----------------
 lhword      | simple,en_stem
 lpart_hword | simple,en_stem
 lword       | simple,en_stem

See Also

ALTER FULLTEXT MAPPING