Elasticsearch get id from TopHits Aggregation using NEST

后端 未结 0 746
耶瑟儿~
耶瑟儿~ 2021-01-14 02:29

So, to get the internal id for a document, I do this:

var hits= response.Hits
.Select(h =>
{
    h.Source.id = h.Id;
    return h.Source;
}).ToList();


        
相关标签:
回答
  • 消灭零回复
提交回复
热议问题