Hi,
I have created custom analyzer like this:
PUT /historical_new_one/_settings
{
"settings": {
"analysis": {
"filter": {
"StopFilterFactory": {
"type": "stop",
"stopwords": "english",
"ignoreCase": true
},
"ASCIIFoldingFilterFactory": {
"type": "asciifolding",
"preserve_original" : false
},
"EdgeNGramFilterFactory": {
"type": "edge_ngram",
"min_gram": 1,
"max_gram": 250
},
"LowerCaseFilterFactory": {
"type": "lowercase"
},
"TrimFilterFactory": {
"type": "trim"
},
"SynonymFilterFactory": {
"type": "synonym",
"synonyms_path" : "/opt/elasticsearch-5.3.0/config/synonyms.txt",
"ignoreCase": true,
"expand": true
}
},
"analyzer": {
"text_general_best": {
"tokenizer": "keyword",
"filter": [
"StopFilterFactory",
"LowerCaseFilterFactory",
"TrimFilterFactory",
"ASCIIFoldingFilterFactory",
"EdgeNGramFilterFactory"
]
},
"exactish": {
"tokenizer": "keyword",
"filter": [
"LowerCaseFilterFactory"
]
},
"text_general_likely_new": {
"tokenizer": "standard",
"filter": [
"StopFilterFactory",
"LowerCaseFilterFactory",
"SynonymFilterFactory",
"ASCIIFoldingFilterFactory"
]
}
}
}
}
}
which acknowledge true, but when i tried to use this multiple custom analyzer(text_general_best,exactish,text_general_likely_new) like this:
GET /historical_new_one/_search
{
"query": {
"bool": {
"must": [
{
"match": {
"bank_client_entity_name": {
"query": "Federal",
"analyzer": ["text_general_likely_new","text_general_best","exactish"]
}
}
}
]
}
}
}
It is showing error:
{
"error": {
"root_cause": [
{
"type": "parsing_exception",
"reason": "[match] unknown token [START_ARRAY] after [analyzer]",
"line": 16,
"col": 29
}
],
"type": "parsing_exception",
"reason": "[match] unknown token [START_ARRAY] after [analyzer]",
"line": 16,
"col": 29
},
"status": 400
}
Please reply for possible ways to use multiple analyzer at a time.