Thursday 20 September 2018

Mongodb Derived fields that update when the data is changed

I have to run calculations ($sum $avg $divide) on some fields that get updated frequently.Right now every time i update the database i run the aggregations to update it again. Is there a better way to do thisI looked at $addsfields pipeline stage but will that make the field dynamic when the data changes

Submitted September 21, 2018 at 12:33AM by jimjim1000

No comments:

Post a Comment