Select distinct objects

(Hichem Noomeni) #1

Hello everyone,

I have mapping that contains fileds like this
"" : {"type": "long"},
"team.value" : {"type" : "text"} with keyword of course.

I may have documents with different but same team.value.
How can I look for distinct objects (distincts ) and return the whole object team.

(Nik Everett) #2

I think you are looking for either field collapsing or the terms aggregation.