Search query for multivalue field in Kibana Search Box


I am using Elasticsearch 5.1 and Kibana 5.1

I need to search multivalue field in Kibana.
For example I have an index with a multivalued field named "tags".
I have 2 documents in the index
{ "tags" : ["search"] }
{ "tags" : ["search", "open_source"] }

Case 1
If I use http get, attaching the following query,
{ "term" : { "tags" : "search" } }
then I can get both of the 2 documents
{ "tags" : ["search"] }
{ "tags" : ["search", "open_source"] }

Case 2
But if I use Kibana interface, and put in the search box a query as follows:
tags: "search"
Then I can only get one document
{ "tags" : ["search"] }
Looks like it only returns the document which has exactly the same match.

But what I need is: if one value match in the multivalue field, it should count as match. I know how to do it using http request with attached document (Case 1), but I don't know how to do it in Kibana Search box (Case 2) . Can any body help me?

(Spencer Alger) #2

Are you putting a space in the query box like you typed here? If so it's probably not matching what you think. Try searching without the space, like tags:"search" not tags: "search"


I tried both tags:"search" and tags: "search"
The result is the same.

Please help me to identify if there is any option for me to search into multivalued fields using Kibana search box.

Thank you!

(Spencer Alger) #4

@Bargs do you have any ideas here?


I found out the reason that in the field value there is a space before search, just like this " search"
That's why I cannot find the match.

(system) #6

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.