Facet and Field Types
Â
FacetFieldType is a property of the facet indicating the type of field is is associated with. Although this closely resembles the FieldType property for a given field, it is not exactly the same.
FacetFieldType | Description |
---|---|
string | this is the most common facet field type indicating that the data this facet’s field holds is of the alphabetic or the alphanumeric type |
numeric | this indicates the data held by the corresponding field is purely numeric. Use this for currency and range facets |
range | for textual field values, only open range is allowed however for numeric field values, selecting this provides option to have the facet type as an open range/checkbox/linklist/slider |
search | this is a special type of facet which can only be of 3 types - |
tab | this is a relatively new facet field type used to hold the tab names for the products, explained below |
Tab:
Hawksearch can index both product and content data. Although we often see search results to be products alone, there are times when you would want to link to a page/ news article / blog post or a document.
This provides a challenge in controlling the search behavior. The user expects the search results to be segregated by the item's type.
Tabs are special facets which have a different UI compared to all the other facets. They are used to provide a grouping mechanism in a tabulated manner for various types of search results.
Â
By default, the type of search result item displayed is of the product type - this can be easily configured in the facet settings:
Â
Sample request could be as follows:
Â
The output format of a tabulated facet will be as below (notice the fieldtype to be tab):
Disambiguation
Field → FieldType
FieldType of a field indicates the storage and indexing methods to be used for the field within OpenSearch.
keywordtext - Field values indexed ""as is"" AND are stemmed
keyword - Field values are NOT stemmed
text - Field values are ONLY stemmed (search only)
unindexed - Stored only, not used for search nor facets
facet - Field values are NOT stemmed
Â
Field → Type
Type of a field is the actual datatype which can be held by the field
Â
Facet → FacetFieldType
This correlates to the Field’s Type attribute. It is the datatype.
Facet → FacetType
This related to the way the facet is intended to be displayed on the front end. This is not to be confused with the DisplayType described next. This is dependent on the FacetFieldType property and changes accordingly. Generally, the FacetType options are the same for String, Numeric and Tabs FacetFieldTypes.
Â
Facet → FacetDisplayType
This is an option to further configure the facet’s display - we can:
Limit the number of facet values displayed - through truncating display
Pack large number of facet values into a smaller area - through scrolling display
Â
Note: This depends on the FacetType. For range facets, this doesn’t apply. For nested facets, scrolling doesn’t apply
Possible Configurations
Field.FieldType | Field.Type | Facet.FacetFieldType | Facet.FacetType | Facet.DisplayType |
---|---|---|---|---|
Field values are NOT stemmed | Boolean | range | checkbox | default |
Field values are NOT stemmed | Boolean | string | checkbox | default |
Field values are NOT stemmed | Boolean | string | checkbox | scrolling |
Field values are NOT stemmed | Boolean | string | link | default |
Field values are NOT stemmed | Datetime | range | checkbox | default |
Field values are NOT stemmed | Datetime | range | link | default |
Field values are NOT stemmed | Datetime | range | openRange | default |
facField values are NOT stemmedt | Datetime | range | slider | default |
Field values are NOT stemmed | GeoPoint | range | checkbox | default |
Field values are NOT stemmed | NULL | range | slider | scrolling |
Field values are NOT stemmed | NULL | string | checkbox | default |
Field values are NOT stemmed | NULL | string | checkbox | scrolling |
Field values are NOT stemmed | NULL | string | checkbox | truncating |
Field values are NOT stemmed | Single | numeric | checkbox | default |
Field values are NOT stemmed | Single | numeric | checkbox | scrolling |
Field values are NOT stemmed | Single | numeric | checkbox | truncating |
Field values are NOT stemmed | Single | numeric | rating | default |
Field values are NOT stemmed | Single | numeric | slider | default |
Field values are NOT stemmed | Single | range | checkbox | default |
Field values are NOT stemmed | Single | range | checkbox | scrolling |
Field values are NOT stemmed | Single | range | checkbox | truncating |
Field values are NOT stemmed | Single | range | link | default |
Field values are NOT stemmed | Single | range | link | scrolling |
Field values are NOT stemmed | Single | range | openRange | default |
Field values are NOT stemmed | Single | range | slider | default |
Field values are NOT stemmed | Single | range | slider | scrolling |
Field values are NOT stemmed | Single | range | slider | truncating |
Field values are NOT stemmed | Single | string | checkbox | default |
Field values are NOT stemmed | Single | string | checkbox | scrolling |
Field values are NOT stemmed | Single | string | checkbox | truncating |
Field values are NOT stemmed | Single | string | link | scrolling |
Field values are NOT stemmed | Single | string | rating | default |
Field values are NOT stemmed | Single | string | rating | scrolling |
Field values are NOT stemmed | String | numeric | checkbox | default |
Field values are NOT stemmed | String | numeric | checkbox | truncating |
Field values are NOT stemmed | String | range | checkbox | default |
Field values are NOT stemmed | String | range | checkbox | scrolling |
Field values are NOT stemmed | String | range | checkbox | truncating |
Field values are NOT stemmed | String | range | link | default |
Field values are NOT stemmed | String | range | link | scrolling |
Field values are NOT stemmed | String | range | openRange | default |
Field values are NOT stemmed | String | range | recentsearches2 | default |
Field values are NOT stemmed | String | search | search | default |
Field values are NOT stemmed | String | string | checkbox | default |
Field values are NOT stemmed | String | string | checkbox | scrolling |
Field values are NOT stemmed | String | string | checkbox | truncating |
Field values are NOT stemmed | String | string | Checkbox list | Text |
Field values are NOT stemmed | String | string | link | default |
Field values are NOT stemmed | String | string | link | scrolling |
Field values are NOT stemmed | String | string | link | truncating |
Field values are NOT stemmed | String | string | nestedcheckbox | default |
Field values are NOT stemmed | String | string | nestedcheckbox | scrolling |
Field values are NOT stemmed | String | string | nestedcheckbox | truncating |
Field values are NOT stemmed | String | string | nestedlinklist | default |
Field values are NOT stemmed | String | string | nestedlinklist | truncating |
Field values are NOT stemmed | String | string | rating | default |
Field values are NOT stemmed | String | string | rating | scrolling |
Field values are NOT stemmed | String | string | rating | truncating |
Field values are NOT stemmed | String | string | size | default |
Field values are NOT stemmed | String | string | size | scrolling |
Field values are NOT stemmed | String | string | size | truncating |
Field values are NOT stemmed | String | string | swatch | default |
Field values are NOT stemmed | String | string | swatch | scrolling |
Field values are NOT stemmed | String | string | swatch | truncating |
Field values are NOT stemmed | String | tab | checkbox | default |
Field values are NOT stemmed | String | tab | link | default |
Field values are NOT stemmed | Boolean | numeric | checkbox | default |
Field values are NOT stemmed | Boolean | string | checkbox | default |
Field values are NOT stemmed | Datetime | range | slider | default |
Field values are NOT stemmed | Single | numeric | checkbox | default |
Field values are NOT stemmed | Single | numeric | checkbox | truncating |
Field values are NOT stemmed | Single | numeric | slider | default |
Field values are NOT stemmed | Single | range | checkbox | default |
Field values are NOT stemmed | Single | range | checkbox | scrolling |
Field values are NOT stemmed | Single | range | link | scrolling |
Field values are NOT stemmed | Single | range | slider | default |
Field values are NOT stemmed | Single | string | checkbox | default |
Field values are NOT stemmed | Single | string | checkbox | scrolling |
Field values are NOT stemmed | Single | string | rating | default |
Field values are NOT stemmed | String | string | checkbox | default |
Field values are NOT stemmed | String | string | checkbox | scrolling |
Field values are NOT stemmed | String | string | checkbox | truncating |
Field values are NOT stemmed | String | string | link | scrolling |
Field values are NOT stemmed | String | string | nestedcheckbox | default |
Field values are NOT stemmed | String | string | nestedcheckbox | scrolling |
Field values are NOT stemmed | String | string | nestedcheckbox | truncating |
Field values are NOT stemmed | String | string | size | default |
Field values are NOT stemmed | String | string | size | scrolling |
Field values are NOT stemmed | String | tab | checkbox | default |
Field values are ONLY stemmed (search only) | String | string | checkbox | scrolling |
Field values are ONLY stemmed (search only) | String | string | link | scrolling |
Stored only, not used for search nor facets | String | string | checkbox | default |
Stored only, not used for search nor facets | String | string | checkbox | scrolling |
Â
Â