-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Closed
Description
I am using Search to get docs according to some query.
What I would expect Size(0) to do is just return all the documents that answer the query.
Instead it returns the full object with 0 results, forcing me to execute the same query again with the number of "to-be" results.
Here is the code I wrote:
var resultsCount = _client.Search<JObject>(s => s.Query(q => q.Terms("string.ProgramId", ids))
.Size(0));
var results = _client.Search<JObject>(s => s.Query(q => q.Terms("string.ProgramId", ids))
.Size((int)resultsCount.Total));
Here is what I get in the first line:
Am I doing something wrong ?
Metadata
Metadata
Assignees
Labels
No labels