Aggregation operations – MongoDB queries to the next level
Commonly, when we work with MongoDB and want to retrieve documents from a collection we make use of the method find or a variation combined with some kind of filtering or processing on the code side. For most cases, the previous technique is going to be good enough, but there will be some other cases where that won’t be enough. For instance: The filtering or processing on the code side is becoming expensive due to the number of documents. The…