URI search query with size -1 doesn't return all the results


I am using version 6.4.2 and when I run a URI search like:

GET my_index/_search?q=version:197&size=-1

I expect that all the hits will be returned, but I get only 10 results out of the tens of hits that should return.

Setting size=-2 returns an error (which is expected) and setting size to any number above 10, returns the requested size (if enough hits are available).

Is there a known bug about this or is size=-1 not supported for URI search?


I have never heard about this -1 value.

Anyway, to extract all data if above 10000, use the scroll API.

Thanks David.

Thanks for clarifying this.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.