Say I have a map that emits the following object:

>>> {"basePoints": 2000, "bonusPoints": 1000}
>>> {"basePoints": 1000, "bonusPoints": 50}
>>> {"basePoints": 10000, "bonusPoints": 5000}

How could I write a reduce in Erlang that would return an aggregate object
like this:

>>> {"basePoints": 13000, "bonusPoints": 6050}

(I would rather not have to write 2 separate views that emit each value
separately if i can help it)

Thanks!

David Park   Software Developer

M 416*.*461*.*2649

*Points  *|  More together.

Connect with us: Points <http://l.points.com/69s8/> | Twitter
<http://l.points.com/uxlj/> | Blog <http://l.points.com/vu4y/> | LinkedIn
<http://l.points.com/rjs4/> | Careers <http://l.points.com/juqh/>

TSX: PTS <http://l.points.com/sgf7/>; NASDAQ: PCOM
<http://l.points.com/ko1o/>

111 Richmond St W., Suite 700, Toronto, ON, M5H 2G4, Canada

Connect with me: LinkedIn <https://www.linkedin.com/in/butterdave>

Reply via email to