title: The field must be an accumulator object
body: <p>I just read about aggregation in mongoose and it seems pretty useful method and I just tested things on my own, So this is my data in database:</p>
  
  <pre><code>[
    {
      product: "chanchuris arayi",
      myidveli: "lg",
      pasi: 12
    },
    {
      product: "kalbasi",
      myidveli: "maiko",
      pasi: 10
    },
    {
      product: "chanchuris arayi",
      myidveli: "zaza",
      pasi: 12
    },
    {
      product: "sulguni",
      myidveli: "shotiko",
      pasi: 7
    },
    {
      product: "kalbasi",
      myidveli: "lg",
      pasi: 10
    }
  ]
  </code></pre>
  
  <p>and this is my code</p>
  
  <pre><code>db.collection.aggregate([
    {
      $match: {}
    },
    {
      $group: {
        _id: "$_id",
        product: "$product",
        pasi: {
          "$sum": "$pasi"
        }
      }
    }
  ])
  </code></pre>
  
  <p>and it gives me error : <strong>The field must be an accumulator object</strong>, when I type $product in _id field it works as I want but not way, so I got confused can anyone explain me how aggregation is working and what is problem with my code?</p>
  
  <p>Thank you!</p>