问题
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:
This is a dup of Elasticsearch query to return all records. To use scan and scroll, look at the NEST documentation here.
来源:https://stackoverflow.com/questions/27955623/is-there-a-way-to-retrieve-all-records-in-a-elasticsearch-nest-query