How to get DocCount for all terms?


(Xiaofei Sun) #1

Hi everyone,

I really want to know how to get document count for all terms. That is, for every term, I want to know how many documents contain it.

I'm using term aggregation now but it seems that it's not a good idea because field data for text is not recommended.

Is there any clever way?

Best


(Simon Willnauer) #2

that's the only way to really do what you want IMO