top button
Flag Notify
    Connect to us
      Site Registration

Site Registration

Explain about Aggregation Pipeline in MongoDB?

0 votes
244 views
Explain about Aggregation Pipeline in MongoDB?
posted Nov 4, 2017 by Jdk

Looking for an answer?  Promote on:
Facebook Share Button Twitter Share Button LinkedIn Share Button

Similar Questions
+2 votes

Is there a way to configure/increase the memory limit(100MB) on the pipeline? What if I have a lot of RAM that can be used by MongoDB?

0 votes

I have an aggregation query given below which I need to pass in as a json string to java app to execute it. Is it possible to do that -

{$unwind:$results},{$match:{result.studentid:11}}

I tried using BasicDBObject.parse but it is returning me the unwinded or flattened results and the result is not segregating on the basis of match.

Is there any other way to do it.

+2 votes

I have an use case where I have find all the matching records and apply the aggregation like count, sum, group by etc .
Can I use such scenarios where I have to use find and aggregate function together or should I find then get the cursor object and have to perform aggregation operation separately

+1 vote

I am having collection with 127706 document. In aggregation pipeline i having 2 group stages. It is giving me result in 1.5 sec.

To optimize it to more I have created index on the fields which I am using in match stages with no success. Is their any to optimize aggregation performance in more way?

I m using mongodb 3.2.1?

0 votes

I am new to mongodb. I am trying to do some aggregation operations like sum, avg, min.. on a collection. And I found that I can do it either using aggregation framework or cursor.forEach(). Which one to use? It will be better if someone explains how both works internally and give me some suggestions.

Thank you in advance

...