WARNING: Version 5.x has passed its EOL date.
This documentation is no longer being maintained and may be removed. If you are running this version, we strongly advise you to upgrade. For the latest information, see the current release documentation.
Fielddata Fields Usage
edit
IMPORTANT: This documentation is no longer updated. Refer to Elastic's version policy and the latest documentation.
Fielddata Fields Usage
editAllows to return the field data representation of a field for each hit.
See the Elasticsearch documentation on Field Data Fields for more detail.
Fluent DSL example
edits => s .FielddataFields(fs => fs .Field(p => p.Name) .Field(p => p.LeadDeveloper) .Field(p => p.StartedOn) )
Object Initializer syntax example
editnew SearchRequest<Project> { FielddataFields = new string [] { "name", "leadDeveloper", "startedOn" } }
Example json output.
{ "fielddata_fields": [ "name", "leadDeveloper", "startedOn" ] }