Skip to main content
Skip table of contents

Configure searchable fields

All fields are always stored in the index database but only configured fields can be used for searching. E.g. if the broadcast list node has a fields "Title", "Comment", "Info" and "Speaker" but only fields "Title" and "Info" are configured for searching, then this node can be found only if title or info are matched for search request, but the result will contains all four fields "Title", "Comment", "Info" and "Speaker". ElasticIndex module use predefined configuration for searchable fields. To include new (e.g. custom) field into searching this field must be configured in ElasticSearch mappings for index. Unfortunately ElasticSearch engine has incompatible changes between major versions 5, 6 and 7 and new fields must be configured depends from used version. See details below

Be aware! When the mappings are getting changed on an existing index you need to Re-index your data. This can be done by "Recreate" the index within BUS Index-Task ((warning) the index will be offline during this time) or you perform the recommended actions mentioned on ElasticSearch  (Search for the "Reindex API").

ElasticSearch 5.5

Configure new field for searching

Use the file Elasticsearch_Bcs_Default_Mapping.json from delivery. This file contains default index mappings. Add new field to "properties" into data type "Node" with using standard ElasticSearch mappings format. See ElasticSearch documentation for details

Add new field to global search (search through all fields)

ElasticSearch 5.5 automatically included all searchable fields into global search (search through all fields) if special "_all" field is enabled in index mappings. See Elasticsearch_Bcs_Default_Mapping.json as example. If this option is enabled all configured fields can be searched in field "_all" or as field name "*" in ElasticIndex search syntax. See BcsSearchService documentation for details

Add all searchable fields to global search

XML
{
  "_all": {
    "enabled": true
  }
}

ElasticSearch 6.x

Configure new field for searching

Use the file Elasticsearch_Bcs_Default_Mapping_60.json from delivery. This file contains default index mappings. Add new field to "properties" into data type "Node" with using standard ElasticSearch mappings format. See ElasticSearch documentation for details

Add new field to global search (search through all fields)

Unfortunately ElasticSearch 6.x and higher isn't support special "_all" field for global search through all searchable fields. To avoid it ElasticIndex simulate special field "__all" but with one important limitation: only text fields can be included into global search. This limitation is based on ElasticSearch limitation to combine only one data type fields together. To include new field text into global search add special instruction to field description in as followed. All fields with this option can be searched in field "__all" or as field name "*" in ElasticIndex search syntax. See BcsSearchService documentation for details

Add all searchable fields to global search

XML
"copy_to": "__all"

E.g.

Add all searchable fields to global search

XML
{
  "Title": {
    "type": "text",
    "copy_to": "__all",
    "fields": {
      "keyword": {
        "type": "keyword",
        "ignore_above": 256
      }
    }
  }
}
JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.