On this page
You can use the Atlas Search
stringFacet type to index string fields for faceting, which allows you
to run a facet query on that field. Atlas Search doesn't apply the analyzer
string fields for faceting.
Atlas Search only supports facet queries against fields
indexed as the
stringFacet type. To perform a normal search also
on the same field, you must index the field as type
Atlas Search doesn't dynamically index
string values for faceting. You must use static
mappings to index
string values for
faceting. You can use the Visual Editor or the JSON Editor in
the Atlas UI to index date fields as the
To define the index for the
stringFacet type, choose your preferred
configuration method in the Atlas UI and then select the
database and collection.
The Atlas Search
stringFacet type has the following parameters:
UI Field Name
Human-readable label that identifies this field type. Value must be
The following index definition example uses the sample_mflix.movies collection. If you have the sample data already loaded on your cluster, you can use the Visual Editor or JSON Editor in the Atlas UI to configure the index. After you select your preferred configuration method, select the database and collection, and refine your index to add field mappings.