Content Component 26.2
Content Component Help

# GetTagNames

Returns the names of all fields in the Content component that have the specified type or field code.

Fields return with their full path, which indicates their hierarchical position in Content (for example, `DOCUMENT/DRETITLE` or `World/Continent/Country/Region/Town`). Content creates this hierarchy when it indexes the documents. If you index XML files, their hierarchy is translated into the field path. If you index IDX files, the IDXFieldPrefix configuration parameter specifies a basic XML hierarchy for the IDX files.

The action returns the attribute `code="NN"`, which specifies the unique field code assigned to each field. For example:

    <responsedata>
       <autn:name code="19">XML/DOCUMENT/COUNTRY/CAPITAL</autn:name>
       <autn:name code="45">XML/DOCUMENT/COUNTRY/LANGUAGE</autn:name>
       <autn:name code="61">XML/DOCUMENT/COUNTRY/POPULATION</autn:name>
       <autn:number_of_fields>3</autn:number_of_fields>
    ...
    </responsedata>

The action also returns a summary count of how many fields of each field type exist. For example:

    <responsedata>
       <autn:name code="19">XML/DOCUMENT/COUNTRY/CAPITAL</autn:name>
    ...
       <autn:count type="index">2</autn:count>
       <autn:count type="reference">1</autn:count>
       <autn:count type="date">2</autn:count>
       <autn:count type="expire">0</autn:count>
    </responsedata>

When you set the FieldStats parameter, `GetTagNames` also includes additional field statistics information. For example:

    <responsedata>
       <autn:name code="2" docOccs="379" totalOccs="379" emptyOccs="379">DOCUMENT</autn:name>
       <autn:name code="3" docOccs="379" totalOccs="379" emptyOccs="0" asciiTextOccs="379" unicodeTextOccs="0" integerOccs="0" floatOccs="0" datetimeOccs="0" geoWKTOccs="0" distinctValuesMinimum="377" distinctValuesAverage="377.00" distinctValuesMaximum="377" byteLengthMinimum="7" byteLengthAverage="8.33" byteLengthMaximum="17">DOCUMENT/DREREFERENCE</autn:name>
       <autn:name code="4" docOccs="357" totalOccs="357" emptyOccs="0" asciiTextOccs="356" unicodeTextOccs="1" integerOccs="0" floatOccs="0" datetimeOccs="0" geoWKTOccs="0" distinctValuesMinimum="285" distinctValuesAverage="285.00" distinctValuesMaximum="285" byteLengthMinimum="14" byteLengthAverage="43.11" byteLengthMaximum="80">DOCUMENT/DRETITLE</autn:name>
       <autn:name code="5" docOccs="354" totalOccs="354" emptyOccs="0" asciiTextOccs="354" unicodeTextOccs="0" integerOccs="0" floatOccs="0" datetimeOccs="0" geoWKTOccs="0" distinctValuesMinimum="1" distinctValuesAverage="1.00" distinctValuesMaximum="1" byteLengthMinimum="1" byteLengthAverage="1.00" byteLengthMaximum="1">DOCUMENT/RECORDTYPE</autn:name>
    ...
    </responsedata>

## Example

    http://12.3.4.56:9100/action=GetTagNames&FieldType=INDEX&FieldCode=23+45

This action requests a list of the field names for the Index fields that have the field codes 23 and 45 assigned to them in Content.

## Optional Parameters

This action accepts the following optional parameters.

Parameter | Description
--- | ---
BaseFieldCodeOnly | Restricts the output to base field codes.
FieldCode | The field codes of the fields to return.
FieldStats | Whether to return field statistics information.
FieldType | The field types of the fields to return.
MaxValues | The maximum number of top results to display.
OutputEncoding | The encoding to convert the results to.
Start | Print results from this position onwards.
Synchronous | Whether to run the action synchronously or asynchronously.
TypeDetails | Shows the properties associated with each field name and code.

This action accepts the following standard ACI action parameters.

Parameter | Description
--- | ---
ActionID | A string to use to identify an ACI action.
FileName | The file to write output to.
ForceTemplateRefresh | Forces the server to load the template from disk.
Output | Writes output to a file.
ResponseFormat | The format of the action output.
Template | The template to use for the action output.
TemplateParamCSVs | A list of variables to use for the specified template.

Copyright 2026 Open Text
Version 26.2 | Last updated April 2026

Send documentation feedback

Close

Send documentation feedback

To send feedback using your default email client, open an email window.

Otherwise, send your feedback and the information below to MFI-swpdl.idoldocsfeedback@opentext.com.

We appreciate your feedback!

Product: Knowledge Discovery Content Component 26.2

Topic Title: GetTagNames