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" <[email protected]> wrote: Hi, Thanks. 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 databases? cheers, Simon -- ***** Email confidentiality notice ***** This message is private and confidential. If you...
