Is there a way to retrieve all records in a (Elast

2020-04-04 15:05发布

I'm doing this query in NEST

var result = elasticClient.Search<SearchItemClass>( s=>
    s.Index("indexName")
     .Type("typeName")
     .Query(q => q.ConstantScore(score => score.Filter(f => f.Term("fieldName", "term"))))
);

And this will return 10 Hits by default.

Is there a way I can get ALL results, WITHOUT indicating .Size(value) or .Take(value)?

Thanks in advance!

1条回答
三岁会撩人
2楼-- · 2020-04-04 15:48

This is a dup of Elasticsearch query to return all records. To use scan and scroll, look at the NEST documentation here.

查看更多
登录 后发表回答