You need the group because your context stretches over multiple documents.
The last stage just translates from set representation to your final output
format. And the first stage gets rid of all false results, which basically
makes group only add true values to the set and as a side-effect also
speeds up the group operator itself. I am sure there are other solutions.
On Friday, April 15, 2016 at 6:58:15 PM UTC+2, Tim Arnold wrote:
I have a collection with documents like this (one fruit, one format, one