I am trying to set-up Elasticsearch environment with .NET connection availability. I was able to do basic queries with customized fuzzy distances, but what I am not able to do is field boosting at the query time. I already tried several tutorials/questions, like Elasticsearch Nest Boost query or Elastic Search using NEST Field Boosting , but NEST doesn't recognize ".OnFieldsWithBoost" or ".OnFields".
I was able to do some field boosting via HTTP API of Elastic search:
POST /products/typeproduct/_search
{
"query" : {
"bool": {
"should": [
{
"match": {
"Title": {
"query": "sometest",
"boost": 10.0
}
}
},
{
"match": {
"Name": "sometest"
}
}
]
}
}
}
but again I was not able to match this query via NEST syntax, as it doesn't allow multiple "match"es in "should".
My final goal is to be able to boost certain fields (Title) over others (Name) and add some fuzziness into the match. Any help would be greatly appreciated.
My Elastic search version: 2.2.0 My NEST version: 2.0.2