Home > Contents > Index >
Template Tag TOC  |   Alpha TOC  |   Tag Family TOC  |   Purpose TOC  |   Annotated TOC  |   Index 

 

INDEXCREATE

Creates a search index.

Syntax

Parameters

INDEX (required)
The full path name of the index to create is required in the tag unless the properties av.defaultindex or verity.defaultindex have been specified in the futuretense.ini file.

FIELDARGUMENT (optional, used by Verity only)
Defines subfields of a Verity search index. Index subfields must be defined when INDEXCREATE is called. Valid FIELDARGUMENT types are DATE and TEXT.

CHARACTERSET (optional)
Constant value representing the character set the index uses. For the AltaVista search engine this value may be 0, 1, or 2 (ISO_LATIN1, UTF8, ASCII8). If you do not specify CHARACTERSET, Content Server uses the value of av.charset in the Content Server properties file.

Because Java Strings are transformed to UTF8, as they pass through the JNI interface to AltaVista, the 0 value only works for 7-bit ASCII. For all other cases, use the value for UTF8.

For the Verity search engine, this value specifies the name of the subdirectory of the common directory where the locale is defined. Note that case-sensitivity is important with directory names. If you do not specify CHARACTERSET, Content Server uses the value of verity.charset in the Content Server properties file.

SEARCHENGINE (optional)
Name of the search engine to use. If SEARCHENGINE is not specified, Content Server uses the value of cs.searchengine from the Content Server properties file.

Description

The INDEXCREATE tag creates a search index. For AltaVista, this creates the directory where the index is stored. For Verity, however, this creates a more complex base structure for the index in the directory specified by the INDEX parameter. In particular, it needs to create the structures that hold the field information for the index. Therefore, the fields that are used must be specified using FIELDARGUMENT tags when the index is created.

errno

The possible values of errno include:

Value
Description
-801
Cannot load search engine.
-802
Unsupported search function. Content Server 3.0 and earlier returned this error; however, Content Server 3.1 and higher no longer return this error.
-803
Create index failed.
-805
No default index specified.
-806
Unknown search engine.
-811
Could not call native method.
-815
Duplicate field values. (Verity only)
-819
Unrecognized field type. (Verity only)
-822
Index already exists.(Verity only)

Example

This AltaVista example creates the Article index used to save article information. The index is stored as C:ArticleIdx.avx, but you don't specify the .avx extension in the tag.

The following Verity example creates the Article index used to save article information. The index is stored as C:ArticleIdx.vix, but you don't specify the .vix extension in the tag. Subfields are specified for headlines and article dates.

See Also

INDEXEXISTS
INDEXDESTROY

  Home > Contents > Index >

FatWire XML Tag Reference
Copyright 2005 by FatWire Software
All rights reserved.