Field types¶
Nixiesearch supports following field types:
- document identifier:
id- special field type for the_idfield (automatically added to every index). - text fields:
text,text[]. - numeric fields:
int,float,long,double,bool,int[],long[],float[],double[]. - geolocation fields:
geopoint - date fields:
date,datetime
Setting field type¶
In the field definition in the index mapping the required field type defines the underlying data type used to store and process the field.
For example, defining a text field looks like this:
schema:
movies:
fields:
title:
type: text # <-- the field type is here
search:
semantic:
model: e5-small
Field type should be defined in advance before you start indexing documents, as it affects:
- the way field is stored on disk (or not stored at all, if you set
stored: false). - underlying index structures if you plan to
search,filter,facetandsortover this field. - document schema check during ingestion.
For further reading, see text, numeric, date and geo fields sections.