I have documents that represent users. They have fields name
and surname
.
Let's say I have two users indexed - Michael Jackson and Michael Starr. I want these sample searches to work:
I tried different queries and got the best results from multi_match query with cross_fields type. There are 2 problems though:
In other words, I want to implement Facebook-like people searching.
I'm pretty new to ElasticSearch so maybe I'm missing something obvious. Sorry if I do.
Jack Mich type of searches
You are using the correct query type. These two should solve your problems.
PS: We all are learning here, doing that together is fun :)