CreateSearchIndex

CreateSearchIndex[dir]

creates a search index from all files in the directory dir and its subdirectories.

CreateSearchIndex[{source1,source2,}]

creates a search index from all sources sourcei.

CreateSearchIndex[sources,"name"]

gives the search index the specified name.

CreateSearchIndex[]

creates an empty search index, which can be added to with AddToSearchIndex.

Details and Options

Examples

open allclose all

Basic Examples  (2)

Create a search index from two files:

TextSearch searches in the index:

Create a search index from all files and subfolders in a folder:

Search the index:

Options  (2)

ContentFieldOptions  (1)

Set a weight of 2 for the "Keywords" field:

DocumentWeightingRules  (1)

Weight documents according to the value of a "Quality" field:

Introduced in 2015
 (10.2)
 |
Updated in 2017
 (11.1)
2019
 (12.0)