title: Alternative to group by for cosmos db
body: <p>Given that cosmos db does not support group by, what is a good alternative to achieve similar functionality:</p>
  
  <pre><code>Select sum(*) , groupterm from tble group by groupterm
  </code></pre>
  
  <p>Can I efficiently achieve this in a cosmos stored procedure?</p>