incubator-couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Randall Leeds <>
Subject Re: Map/reduce and transactions
Date Fri, 13 Aug 2010 17:12:38 GMT
You could keep the summing in Couch as long as you have a balance-forward
transaction to start the new month with some data, as Chris suggested.

Also, keep in mind that Couch can do this sum more efficiently than SQL
because the reduce function to sum the view will store intermediate values
in the index. Incremental updates are relatively cheap and you never have to
compute the entire sum except the first time you insert your data.

Sent from my interstellar unicorn.

On Aug 13, 2010 10:06 AM, "Simon Woodhead" <>



The index in the banking example in the book will indeed grow as
> transactions happen. If you have...
We're already rolling up by month but would I be right in understanding your
suggestion to be that the rollups should be in a separate database? We were
thinking of another doc type in the same database to contain an opening and
closing balance. This enables us to roll-up but not throw away. I guess the
summing would need to be partly in app login if they were in two separate



***** Email confidentiality notice *****

This message is private and confidential. If you...

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message